in reply to Re: Re: Coloring text using TK?
in thread Coloring text using TK?

Not sure what your $wid exactly is, but this might help you (works for me with Tk::ROText as $wid):
$wid->tag('bind', "black"); $wid->tag('bind', "red"); $wid->tag('bind', "green"); $wid->tag('configure', "black", -foreground=>"black"); $wid->tag('configure', "red", -foreground=>"red"); $wid->tag('configure', "green", -foreground=>"darkgreen"); $wid->insert("end",$_,$color); # where $color can be "black", "red", o +r "green"
HTH
--
B10m