Game Development Community

GUIText doesnt render

by Dieter Eichert · in Torque X 2D · 03/27/2008 (6:39 am) · 2 replies

Hello.

since i updated to tx 2.0 the GUIText isnt visible.
bgImage = new GUIBitmap();
...
            bgImage.Folder = this; // this is a GUISceneview

 textStyle = new GUITextStyle();
            textStyle.FontType = "arial";            
            //textStyle.TextColor = Color.White;
            textStyle.IsOpaque = true;         
            textStyle.SizeToText = false;           
            //textStyle.Anchor = AnchorFlags.Bottom | AnchorFlags.Right;

    // create a text label to Display the value
            Text = new GUIText();
            Text.Style = textStyle;
            Text.Text = "TEST";
            Text.Position = position + new Vector2(2,2);
            Text.Size = new Vector2(size.X - 4, size.Y - 4);
            Text.Visible = true;
            Text.Folder = folder;
i had deactivated the textColor, because the property is a little bit strange. Is there a major change, or other issue, concerning GUIText handling?

thanks,
max.

#1
03/27/2008 (7:48 am)
TextColor is now an array

so its something like:

textStyle.TextColor[CustomColor.ColorBase] = Color.White;



If that doesnt fix it try "Arial12" or "Arial14" as your font type.
#2
03/31/2008 (2:38 am)
Thank you!