Gtk - кросплатформовий набір інструментів для створення графічних інтерфейсів користувача
Підключення бібліотеки GtkSharp
dotnet new console
dotnet add package GtkSharp
Program.cs
using Gtk;
class Program
{
public static void Main()
{
Application.Init();
new FirstWindow();
Application.Run();
}
public static void Quit()
{
Application.Quit();
}
}
FirstWindow.cs
using Gtk;
class FirstWindow : Window
{
public FirstWindow() : base("Test")
{
SetDefaultSize(1200, 900);
SetPosition(WindowPosition.Center);
Maximize();
DeleteEvent += delegate
{
Program.Quit();
};
ShowAll();
}
}
Запуск програми
dotnet run
accounting.org.ua © 2023 рік