Blink.GUI.Label.Draw C# (CSharp) Method

Draw() public method

public Draw ( SpriteBatch sb ) : void
sb Microsoft.Xna.Framework.Graphics.SpriteBatch
return void
        public virtual void Draw(SpriteBatch sb)
        {
            Vector2 size = new Vector2(12 * text.Length, 16);
            sb.DrawString(font, text, pos - (size*center), color);
        }

Usage Example

Ejemplo n.º 1
0
 public void Draw(SpriteBatch sb)
 {
     title.Draw(sb);
     foreach (TextButton b in buttons)
     {
         b.Draw(sb);
     }
 }