mirror of https://github.com/buggins/dlangui.git
90 lines
4.4 KiB
HTML
90 lines
4.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
|
|
<html>
|
|
<head>
|
|
<meta charset='utf-8'>
|
|
<meta http-equiv="X-UA-Compatible" content="chrome=1">
|
|
<link href='https://fonts.googleapis.com/css?family=Chivo:900' rel='stylesheet' type='text/css'>
|
|
<link rel="stylesheet" type="text/css" href="stylesheets/stylesheet.css" media="screen" />
|
|
<link rel="stylesheet" type="text/css" href="stylesheets/pygment_trac.css" media="screen" />
|
|
<link rel="stylesheet" type="text/css" href="stylesheets/print.css" media="print" />
|
|
<!--[if lt IE 9]>
|
|
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
|
|
<![endif]-->
|
|
<title>DlangUI - cross platform GUI library for D programming language - dlangui.all</title>
|
|
</head>
|
|
<body>
|
|
<div id="container">
|
|
<div class="inner">
|
|
<header>
|
|
<h1>DlangUI</h1>
|
|
<h2>Cross Platform GUI for D programming language</h2>
|
|
</header>
|
|
<section id="downloads" class="clearfix">
|
|
<a href="index.html" id="home" class="button"><span>Home</span></a>
|
|
<a href="api.html" id="home" class="button"><span>API Docs</span></a>
|
|
<a href="screenshots.html" id="home" class="button"><span>Screenshots</span></a>
|
|
<a href="https://github.com/buggins/dlangui/zipball/master" id="download-zip" class="button"><span>Download .zip</span></a>
|
|
<!--a href="https://github.com/buggins/dlangui/tarball/master" id="download-tar-gz" class="button"><span>Download .tar.gz</span></a-->
|
|
<a href="https://github.com/buggins/dlangui" id="view-on-github" class="button"><span>View on GitHub</span></a>
|
|
</section>
|
|
|
|
<hr>
|
|
<section id="main_content">
|
|
<h1>dlangui.all</h1>
|
|
<!-- Generated by Ddoc from src\dlangui\all.d -->
|
|
This module is just to simplify import of most useful DLANGUI modules.
|
|
<br><br>
|
|
<b>Synopsis:</b><br>
|
|
<pre class="d_code"><font color=green>// helloworld
|
|
</font><font color=blue>import</font> dlangui.<u>all</u>;
|
|
<font color=green>// required in one of modules
|
|
</font><font color=blue>mixin</font> APP_ENTRY_POINT;
|
|
|
|
<font color=green>/// entry point for dlangui based application
|
|
</font><font color=blue>extern</font> (C) <font color=blue>int</font> UIAppMain(string[] args) {
|
|
<font color=green>// resource directory search paths
|
|
</font> string[] resourceDirs = [
|
|
appendPath(exePath, <font color=red>"../../../res/"</font>), <font color=green>// for Visual D and DUB builds
|
|
</font> appendPath(exePath, <font color=red>"../../../../res/"</font>), <font color=green>// for Mono-D builds
|
|
</font> appendPath(exePath, <font color=red>"res/"</font>) <font color=green>// when res dir is located at the same directory as executable
|
|
</font> ];
|
|
|
|
<font color=green>// setup resource directories - will use only existing directories
|
|
</font> Platform.instance.resourceDirs = resourceDirs;
|
|
<font color=green>// select translation file - for english language
|
|
</font> Platform.instance.uiLanguage = <font color=red>"en"</font>;
|
|
<font color=green>// load theme from file "theme_default.xml"
|
|
</font> Platform.instance.uiTheme = <font color=red>"theme_default"</font>;
|
|
|
|
<font color=green>// create window
|
|
</font> Window window = Platform.instance.createWindow(<font color=red>"My Window"</font>, <font color=blue>null</font>);
|
|
<font color=green>// create some widget to show in window
|
|
</font> window.mainWidget = (<font color=blue>new</font> Button()).text(<font color=red>"Hello world"d</font>);
|
|
<font color=green>// show window
|
|
</font> window.show();
|
|
<font color=green>// run message loop
|
|
</font> <font color=blue>return</font> Platform.instance.enterMessageLoop();
|
|
}
|
|
|
|
|
|
</pre>
|
|
|
|
<br><br>
|
|
<b>License:</b><br>
|
|
Boost License 1.0
|
|
<br><br>
|
|
<b>Authors:</b><br>
|
|
Vadim Lopatin, coolreader.org@gmail.com<br><br>
|
|
|
|
|
|
</section>
|
|
<footer>
|
|
Dlangui is maintained by <a href="https://github.com/buggins">buggins</a><br>
|
|
This page was generated by <a href="http://pages.github.com">GitHub Pages</a>. Tactile theme by <a href="https://twitter.com/jasonlong">Jason Long</a>.
|
|
</footer>
|
|
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|