Plus minus sign in a latex or a text

Dear all,

Can you please tell me how to make ± or -+ sign together in a text before I get crazy :slight_smile: ?
Appreciated in advance.

I used to write things like : Form("%3.2f^{#circ}", 455.34556), but now this Form method in TLatex doesn’t wok. #pm doesn’t work in the example below.
cout << “Integral: “<< 100<<Form(”/pm”)<< 5<< endl;
cout << “Integral: “<< 100<<Form(”#pm”)<< 5<< endl;
cout << “Integral: “<< 100<<”#pm”<< 5<< endl;

void pm(){
   cout << "Integral:" << 100<< "±" << 5<< endl;


root [1] .x pm.C

Note: TLatex “#pm” is for graphics only.

That’ s painful and shame! :frowning:

What do you mean ? graphics text on a canvas is not the same as the characters you get on terminal.

I mean I wish only #pm should have worked. Anyway, this is what it is.

TLatex allows to draw math formulae on screen . It has the LaTeX syntax.
The text on the terminal is not at all the same, you cannot have math formulae there.
Each character is defined by its code. You can do the opposite using TMathText (available also via TLatex) ie: use special characters on graphics rendering.