*
The moose likes HTML, CSS and JavaScript and the fly likes How to set the fontcolor and size for the selected text of text area ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "How to set the fontcolor and size for the selected text of text area ?" Watch "How to set the fontcolor and size for the selected text of text area ?" New topic
Author

How to set the fontcolor and size for the selected text of text area ?

Paul Phoby
Greenhorn

Joined: Sep 19, 2002
Posts: 13
How to set the fontcolor and size for the selected text of text area ?
I am using the below mentioned code for to select the text.
document.selection.createRange().text
Now I want to set font size, font color and bold to that selected string of text area.
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
You will not be able to change it do to the fact it is in a text area....you can not change the formatting for a part of a text area...all has to be the same.
 
Consider Paul's rocket mass heater.
 
subject: How to set the fontcolor and size for the selected text of text area ?
 
Similar Threads
JEditorPane, ranges, attributes
how check the font size in IE and NS
Font in JTextComponent
color in selected text in text area
changing font type and size