35 lines
916 B
C#
35 lines
916 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using Microsoft.Xna.Framework;
|
|
using Microsoft.Xna.Framework.Graphics;
|
|
|
|
namespace MrAG
|
|
{
|
|
public partial class Gui
|
|
{
|
|
public class ImageBox : Base
|
|
{
|
|
public string Text = "";
|
|
|
|
public SpriteFont Font = MrAG.Draw.Font;
|
|
|
|
public Color BorderColor = Color.Black;
|
|
public Color ImageColor = Color.White;
|
|
public Texture2D Texture;
|
|
public int BorderSize;
|
|
|
|
public override void Draw()
|
|
{
|
|
if (this.Texture != null)
|
|
MrAG.Draw.Texture(this.Texture, this.X + this.BorderSize, this.Y + this.BorderSize, this.Width - (this.BorderSize * 2), this.Height - (this.BorderSize * 2), this.ImageColor);
|
|
|
|
MrAG.Draw.OutlinedBox(this.X, this.Y, this.Width, this.Height, this.BorderSize, this.BorderColor);
|
|
|
|
base.Draw();
|
|
}
|
|
}
|
|
}
|
|
}
|