Letters don't have colors, but HTML elements and fonts can have them. This is not possible with "regular" text box, you need to design or use very special control to do this. For a rudimentary code sample, please consider this:
<p contenteditable="true">This is an editable paragraph.</p>
(The sample is taken from
http://www.w3schools.com/tags/att_global_contenteditable.asp[
^].)
If click on this paragraph and you try to paste some colored/formatted fragment text, you will see that different colors and fonts will work. Try also this:
<p contenteditable="true">This is an editable paragraph. <span style="color:red">This text is colored.</span></p>
I don't know your purpose. Want something more serious or practical? See how some JavaScript/HTML WYSIWYG editor work, like this one:
http://en.wikipedia.org/wiki/TinyMCE[
^],
http://www.tinymce.com/[
^].
Good luck,
—SA