How can I change text alignment for GUI?

i want do alignment of text in GUI.SKIN through scripting upper,middle,center not directly

changing in the GUI.SKIN.Through script i want to change the alignment of text in label

something like this

GUISkin.settings = TextAlignment.left;

See GUIStyle (scripting reference).

You can create/modify GUIStyles by scripting and GUI calls accept a gui style to be passed.


GUI.Button(rect, "Press me!", customStyle);