Can't use word wrap with different font sizes?

I’m trying to build a simple custom skin. I need to be able to display large texts, and with a font larger than the standard font size. However, for some reason, whenever I enable word wrap, it removes the effect of the font size.

Has anyone else experienced this? Any work arounds?

For what its worth, I’m using Unity 3. I’ve included a real quick demo of a scene demonstrating the issue.

404038–13907–$wordWrapTest.unitypackage (24.2 KB)

So, I was able to get wordwrap and font styles to work properly by explicitly setting the Font in the custom style I was using. Seems strange it couldn’t do this with just the default font, but at least there is a work around that exists.

But this has introduced a new, minor problem. When I set the custom style font to my new font, and the main GUISkin font to the default and I get a warning as follows

And the text areas go blank.

This happens even if I explicitly set the font back to the default fonts. Looks like this will force me to use my own custom font (which isn’t a big deal).

This is still an issue, as I discovered tonight. There’s also a UnityAnswers thread pertaining to the problem at http://answers.unity3d.com/questions/36842/word-wrap-forces-font-to-revert-to-default-settings/39957.

It seems that wordwrap can only be used with custom text styling if the style’s font face is also customized.

Yes, it is very odd that it doesn’t work with the default font.

In order for wordWrap and fontsize to work correctly, you need to set the Font in the GUIStyle, even thought it maybe the same as default font in the GUIStyle.

I guess if we choose to use the default font and don’t define the font in the style, when wordWrap is enabled, it uses the default font size as well. It disregard the font size we set. We need to bare that in mind.

I just found this same problem after wasting an hour trying to figure out what was causing it. Is really poor that this hasn’t been fixed since 2010!