How to adjust GUI.Label text so that each letter have the same space no matter the size?

21 Views Asked by At

I'm trying to display simple text in UnityEditor window

So I did the following:

GUI.Label(new Rect(position.width - (position.width / 2), 60, 200, 20), "..........................", label);
GUI.Label(new Rect(position.width - (position.width / 2), 80, 200, 20), "..oo..oo..oo..oo..oo..oo..", label);

so it should show in the editor window with the same spacing between letters to align.

Like bellow:

".........................."
"..oo..oo..oo..oo..oo..oo.."

As you can see above they have the same spacing and the same occupied width but in the editor window it shows the following:

enter image description here

As you can see above the letter spacing is different (letter o takes more space than letter .)

How can I solve this problem?

0

There are 0 best solutions below