Files
RemSox/UI/GUI/UIEelements/Controls/Panel.cs
T

25 lines
614 B
C#

using RemSox.UI.GUI.Rendering;
using System.Drawing;
namespace RemSox.UI.GUI.UIEelements.Controls;
public class Panel() : Control("Panel")
{
public override IEnumerable<RenderCommand> ToPrimitives(int windowId)
{
yield return new RenderCommand
{
WindowId = windowId,
ElementId = PrimitiveId(0),
Type = RenderCommandType.DrawFilledRect,
Position = Position,
Properties = new Dictionary<string, object?>
{
["Color"] = BackgroundColor,
["Size"] = Size,
}
};
}
}