I downloaded a sample paint program and I am trying to extend it further.
Im using the wscpaintbrushprogramv1.1 http://www.w3coder.com/vbnet/w3PaintBrush.aspx
I would like to add a type tool in addition to the existing circle, pen and rectangle tool available.
here is the sub routine:
Private Sub RdText_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RdText.CheckedChanged If RdText.Checked Then ' To specify draw circle Dim g As Graphics Dim newfont As Font = New Font("Arial", 10)
g.DrawString("ee", newfont, New SolidBrush(Color.Black), -34, -54, System.Drawing.StringFormat.GenericDefault)
End If End Sub
does anyone know of tutorials on how to add a type tool to a paint style program?
I did something similar in ChalkTalk. If you copy the code for the rectangle tool, then instead of drawing the rectangle, you add a textbox object the same size/position as the rectangle. Then when the users finished with textbox, you iterate through the controls collection changing the textboxes into captions. (With transparent backcolors)