Is there simple way to color background, highlight some parts of background, equation or some parts of equation? something like these Latex codes:

  1. {\bgcolor{color name}{equation}} or {\bg{color name}{equation}} for background


  1. {\color{color name}{equation}} or {\mathcolor{color name}{equation}} to color equations


  • by this code $a^2 + {\color{red} b^2}=c^2$ b^2 must become red

  • and by this one $a^2 + {\bg{red}b^2}=c^2$ its background must become red.

  • $\begingroup$ Why not work with these very LaTeX codes? Do they bother you to use them? Don't know about 1 but 2 renders output. $\endgroup$ – user36790 Jul 11 '16 at 16:31
  • $\begingroup$ @MAFIA36790 they don't work for background $\color{red} a^2$ $\endgroup$ – Achmed Jul 11 '16 at 17:02
  • 1
    $\begingroup$ use \color{red}{a^2}; you need to complete the brace. $\endgroup$ – user36790 Jul 11 '16 at 17:10
  • $\begingroup$ @MAFIA36790 ok I'll check for that, how about background, How to highlight whole or a part of background? $\endgroup$ – Achmed Jul 11 '16 at 17:14
  • $\begingroup$ @MAFIA36790 I checked it but don't work for mathematical equations $\endgroup$ – Achmed Jul 11 '16 at 17:21
  • $\begingroup$ What were your codes? \color{red}{a^2} works fine at any MathJax-enabled site of SE. $\endgroup$ – user36790 Jul 11 '16 at 17:27
  • 1
    $\begingroup$ Also, as I said earlier, you need to complete the braces. $\endgroup$ – user36790 Jul 11 '16 at 17:29

You must log in to answer this question.

Browse other questions tagged .