DlangUI

FrankLike via Digitalmars-d-announce digitalmars-d-announce at puremagic.com
Tue May 20 15:18:12 PDT 2014


> Helloworld:
>
> // main.d
> import dlangui.all;
> mixin DLANGUI_ENTRY_POINT;
>
> /// entry point for dlangui based application
> extern (C) int UIAppMain(string[] args) {
>     // resource directory search paths
>     string[] resourceDirs = [
>         appendPath(exePath, "../res/"),   // for Visual D and 
> DUB builds
>         appendPath(exePath, "../../res/") // for Mono-D builds
>     ];
>
>     // setup resource directories - will use only existing 
> directories
>     Platform.instance.resourceDirs = resourceDirs;
>     // select translation file - for english language
>     Platform.instance.uiLanguage = "en";
>     // load theme from file "theme_default.xml"
>     Platform.instance.uiTheme = "theme_default";
>
>     // create window
>     Window window = Platform.instance.createWindow("My Window", 
> null);
>     // create some widget to show in window
>     window.mainWidget = (new Button()).text("Hello 
> world"d).textColor(0xFF0000); // red text
>     // show window
>     window.show();
>     // run message loop
>     return Platform.instance.enterMessageLoop();
> }
>
> DDOC generated documentation can be found there: 
> https://github.com/buggins/dlangui/tree/master/docs
> For more info see readme and example1 code.
>
> I would be glad to see any feedback.
> Can this project be useful for someone? What features/widgets 
> are must have for you?
>
>
> Best regards,
>      Vadim  <coolreader.org at gmail.com>
> 	
Nice work.
Some days ago,I test the hello world ,it need 19M Memory 
Usage,but now,it's 31M,maybe have some error?
Thank you.
Nice work.



More information about the Digitalmars-d-announce mailing list