I wold like to be able to change the colours and fonts of fractions entered into a Moodle (vs. 1.9) glossary. I can copy and paste from MathType fine, but even though I've changed the colour in MathType to yellow the fraction still shows up as black on the Moodle page. Is there some code I can add to change the fraction's colour once it's in Moodle? Thanks.

### Changing text colour when I copy from MathType into Moodle 1.9

Number of replies: 2### Re: Changing text colour when I copy from MathType into Moodle 1.9

You don't say *how* you're pasting the equations into Moodle, but I'm assuming you're using the MathType "translator" named "Moodle: TeX filter" (which is in MathType's **Cut & Copy Preferences** dialog). If that's how you're doing it, then no; there's no way to color an equation in MathType and have that color retained when you paste it into Moodle. You should be able to add the color once it's in Moodle, but MathType won't translate the color for you. (If this feature is important to you, please write support@dessci.com and let us know.)

You do this with the syntax {\color{ColorName}{EquationGoesHere}}, where Colorname is one of these 8 colors: white, black, red, green, blue, cyan, magenta, yellow. (There may be other colors that work, but these 8 work.) So this is the code for the equation of a circle centered at the origin, colored red:

This works in my installation of Moodle 1.9; I'm not sure whether it works in other versions.

One additional glitch -- and I'm not sure if perhaps this was just me not doing it right -- is that no matter where you put \color within the equation, it colors the entire equation. If you put more than one color declaration, it seems to take only the last one.

### Re: Changing text colour when I copy from MathType into Moodle 1.9

In addition to what Bob said the main problem is really in **renderer** of your maths.

MathTran does not support colours at all

Mimetex does support those few colours that Bob mentioned (moodle is using this if no other option is available in tex filter)

Most distributions of Latex (TexLive, MikTex,...) do support color if you have added to Tex filter settings and LaTeX preamble

\usepackage[usenames]{color}

Default LaTeX preamble does not support colours.

MathTex supports 68 standard color names known to dvips and colors like #XXXXXX

Finally MathJax supports all colors and you can use either \color{...}{...} for any parts of mathematical notations or add colors to html elements (for example spans) around mathematical notations (for example with editor color tools) and mathJax takes the colors from surrounding element. MathJax supports also scaling http://www.mathjax.org/demos/scaling-math/ that makes it much more flexible renderer that image based latex renderers. All you need to do to use mathJax with moodle 1.9 is to add the necessary script tags for example to your theme header.html or meta.php - or upgrade to moodle 2 that has a couple of other tools available