alternative to assert
[gtkD.git] / gtkD / demos / gtk / HelloWorld.d
blobef1820cd2b5322a87beffe5f5769998522f50ded
1 /*
2 * This file is part of gtkD.
4 * gtkD is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License as published by
6 * the Free Software Foundation; either version 2.1 of the License, or
7 * (at your option) any later version.
9 * gtkD is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with gtkD; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 module gtk.HelloWorld;
21 private import gtk.MainWindow;
22 private import gtk.Label;
23 private import gtk.GtkD;
25 private import gtk.Dialog;
26 private import gtk.VBox;
27 private import gtk.HButtonBox;
29 private import std.stdio;
31 private import gtkc.gtktypes;
33 class HelloWorld : MainWindow
35 this()
37 super("GtkD");
38 setBorderWidth(10);
39 add(new Label("Hello World"));
41 showAll();
46 private import gtkc.Loader;
48 void main(char[][] args)
51 Gtk.init(args);
52 new HelloWorld();
53 Gtk.main();