Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: coloring only some substring

  • To: mathgroup at
  • Subject: [mg54990] Re: coloring only some substring
  • From: dh <dh at>
  • Date: Wed, 9 Mar 2005 06:34:17 -0500 (EST)
  • References: <d0jtph$mvg$>
  • Sender: owner-wri-mathgroup at

the magic word is: FontColor:

lst = {"to", "be", "or", "not", "to", "be", "bottom"};
lst /. x : "to" -> StyleForm[x, FontColor -> Hue[1]]

Sincerely, Daniel

fartous at wrote:
> hi
> i have the list:
> lst={"to","be","or","not","to","be","bottom"}
> how to search for the string "to" and then to output the whole content of List 
> lst but with the substring "to" colored in red.
> thanks
> jack

  • Prev by Date: Re: Re: where is DrBob's web site?
  • Next by Date: Re: substrings at the end of words
  • Previous by thread: coloring only some substring
  • Next by thread: Re: coloring only some substring