-
-
Notifications
You must be signed in to change notification settings - Fork 337
Tutorial 1 Hello Eto.Forms
Petr Hluzín edited this page Aug 15, 2014
·
9 revisions
This tutorial will teach you how to create a simple "Hello World" application using Eto.Forms
-
Follow Preparing your solution to create your solution
-
Create a new class for your main form:
class MyForm : Eto.Forms.Form { public MyForm() { // sets the client (inner) size of the window for your content this.ClientSize = new Eto.Drawing.Size(600, 400); this.Title = "Hello, Eto.Forms"; } }
-
In your main() function, create an Application object and handle the Initialized event:
var app = new Eto.Forms.Application (); app.Initialized += delegate { // only create new controls/forms/etc during or after this event app.MainForm = new MyForm (); app.MainForm.Show (); }; app.Run (args);
-
In order to run your application, follow Running your application