An open API service indexing awesome lists of open source software.

https://github.com/cyl18/openlg

Just a C# graphics library.
https://github.com/cyl18/openlg

Last synced: 3 months ago
JSON representation

Just a C# graphics library.

Awesome Lists containing this project

README

        

# OpenLG

Just a C# graphics library using System.Drawing.Common.

## What is LG?

This guy [Lasm_Gratel](https://github.com/NanamiArihara)

## Usage

### Definition..

```csharp
public class Test1 : HorizontalLayout
{
[Margin(20, 20)]
public RenderableText Text1 { get; } = "Fork You LG1";

[Margin(20, 20)]
public ICollection Text2 { get; } = new RenderableText[] { "1", "2", "3" };

[Margin(20, 10)]
public RenderableText Text3 { get; } = new RenderableText("fork you lg3", Color.Aqua);

[Margin(3, 3)]
public Vert Vert { get; } = new Vert();
}

public class Vert : VerticalLayout
{
[Margin(20, 20)]
public RenderableText Text1 { get; } = "Fork You LGVert1";

[Margin(20, 10)]
public RenderableText Text3 { get; } = new RenderableText("fork you lgvert3", Color.Aqua);
}
```

### Then..

```csharp
new Test1().Render().FillBackground(Brushes.Black).Save("test.png");
```

### Result..

![1](Images/result.png)