diff --git a/dub.json b/dub.json index 65cf3ef1..7bdd38ae 100644 --- a/dub.json +++ b/dub.json @@ -22,16 +22,7 @@ "versions-posix": ["USE_SDL", "USE_OPENGL"], "versions-windows": ["Unicode"], - - "sourceFiles": [ - "project.ddoc" - ], - - "excludedSourceFiles": [ - "../../src/api.d", - "../../src/index.d", - "../../src/screenshots.d" - ], + "versions": ["EmbedStandardResources"], "sourcePaths": [ "3rdparty" @@ -45,16 +36,6 @@ "derelict-ft": ">=1.0.0", "derelict-sdl2": ">=1.9.1" }, - "configurations": [ - { - "name": "normal", - "versions": ["EmbedStandardResources"] - }, - { - "name": "no-standard-resources", - "copyFiles": ["res"] - } - ], "-ddoxFilterArgs": ["--unittest-examples", "--min-protection=Protected", "--ex", "win32.", "--ex", "src.dlangui"] }, "./examples/helloworld/", @@ -63,9 +44,9 @@ ], "dependencies": { - "dlangui:dlanguilib": "*", - "dlangui:example1": "*", - "dlangui:helloworld": "*", - "dlangui:tetris": "*" + "dlangui:dlanguilib": "~master", + "dlangui:example1": "~master", + "dlangui:helloworld": "~master", + "dlangui:tetris": "~master" } } diff --git a/examples/example1/dub.json b/examples/example1/dub.json index 4aa252e5..aa590aa6 100644 --- a/examples/example1/dub.json +++ b/examples/example1/dub.json @@ -7,6 +7,7 @@ "targetPath": "bin", "targetType": "executable", + "targetName": "example1", "copyFiles": ["res"], diff --git a/examples/example1/example1.visualdproj b/examples/example1/example1.visualdproj index 96dd193b..88c93a22 100644 --- a/examples/example1/example1.visualdproj +++ b/examples/example1/example1.visualdproj @@ -189,6 +189,6 @@ *.obj;*.cmd;*.build;*.json;*.dep - + diff --git a/examples/helloworld/dub.json b/examples/helloworld/dub.json index ea5d49c1..48d0d18d 100644 --- a/examples/helloworld/dub.json +++ b/examples/helloworld/dub.json @@ -6,6 +6,7 @@ "authors": ["Vadim Lopatin"], "targetPath": "bin", + "targetName": "helloworld", "targetType": "executable", "dependencies": { diff --git a/examples/helloworld/helloworld.dproj b/examples/helloworld/helloworld.dproj index 949bdbc0..94a69beb 100644 --- a/examples/helloworld/helloworld.dproj +++ b/examples/helloworld/helloworld.dproj @@ -52,6 +52,6 @@ Executable - + \ No newline at end of file diff --git a/examples/tetris/tetris.visualdproj b/examples/tetris/tetris.visualdproj index 2e8c2b77..2f140968 100644 --- a/examples/tetris/tetris.visualdproj +++ b/examples/tetris/tetris.visualdproj @@ -192,7 +192,7 @@ - + diff --git a/src/api.d b/src/api.d deleted file mode 100644 index d4cfe5f4..00000000 --- a/src/api.d +++ /dev/null @@ -1,6 +0,0 @@ -Ddoc - - -

By Modules

- $(MODULE_TREE) - diff --git a/src/index.d b/src/index.d deleted file mode 100644 index f3f8713a..00000000 --- a/src/index.d +++ /dev/null @@ -1,274 +0,0 @@ -Ddoc - -

-Dlang UI

- -

GUI for D programming language, written in D.

- - Alpha stage of development. - - - -

Widgets

- -

Currently implemented widgets:

- - - -

Layouts

- -Similar to layouts in Android - -

-List Views

- -

Lists are implemented similar to Android UI API.

- -

TODOs:

- -

-Resources

- -

Resources like fonts and images use reference counting. For proper resource freeing, always destroy widgets implicitly.

- -

-Styles and Themes

- -

Styles and themes are a bit similar to ones in Android API.

- -

-Win32 builds

- -

Build and run using DUB:

- ------------------------ - git clone https://github.com/buggins/dlangui.git - cd dlangui - dub run dlangui:example1 ------------------------ - -

To develop using Visual-D, download sources for dlabgui and dependencies into some directory:

- ------------------------ - git clone https://github.com/buggins/dlangui.git - git clone https://github.com/DerelictOrg/DerelictUtil.git - git clone https://github.com/DerelictOrg/DerelictGL3.git - git clone https://github.com/DerelictOrg/DerelictFI.git - git clone https://github.com/DerelictOrg/DerelictFT.git - git clone https://github.com/DerelictOrg/DerelictSDL2.git ------------------------ - -

Then open .sln using Visual D.

- -

-Linux builds

- -

For linux build with SDL2 backend, following libraries are required:

- ------------------------ - libsdl2 ------------------------ - -

To build dlangui apps with XCB backend, development packages for following libraries required for XCB backend build:

- ------------------------ - xcb, xcb-util, xcb-shm, xcb-image, xcb-keysyms, X11-xcb, X11 ------------------------ - -

E.g. in Ubuntu, you can use following command to enable SDL2 backend builds:

- ------------------------ - sudo apt-get install libsdl2-dev ------------------------ - -

or (for XCB backend)

- ------------------------ - sudo apt-get install libxcb-image0-dev libxcb-shm0-dev libxcb-keysyms1-dev libfreeimage-dev ------------------------ - - -

In runtime, .so for following libraries are being loaded (binary packages required):

- ------------------------ - freetype, opengl, freeimage ------------------------ - -

Build and run on Linux using DUB:

- ------------------------ - dub run dlangui:example1 ------------------------ - -

Development using Mono-D:

- -

You need fresh version of MonoDevelop to use Mono-D. It can be installed from PPA repository.

- ------------------------ - sudo add-apt-repository ppa:ermshiperete/monodevelop - sudo apt-get update - sudo apt-get install monodevelop-current ------------------------ - -

-Other platforms

- -

-Third party components used

- -

-Hello World

- -Sample code: - ------------------------------------------- -// 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(); -} --------------------------------- - -Sample dub.json: --------------------------------- -{ - "name": "myproject", - "description": "sample DLangUI project", - "homepage": "https://github.com/buggins/dlangui", - "license": "Boost", - "authors": ["Vadim Lopatin"], - - "targetName": "example", - "targetPath": "bin", - "targetType": "executable", - - "sourcePaths": ["src"], - - "sourceFiles": [ - "src/app.d" - ], - - "copyFiles-windows": [ - "lib/FreeImage.dll" - ], - - "copyFiles": [ - "res" - ], - - "dependencies": { - "dlangui:dlanguilib": "~master" - } -} --------------------------------- - -There is sample project which is using DLangUI. - -https://github.com/buggins/dlangide diff --git a/src/screenshots.d b/src/screenshots.d deleted file mode 100644 index ee424af3..00000000 --- a/src/screenshots.d +++ /dev/null @@ -1,21 +0,0 @@ -Ddoc - -
- -

Buttons demo

- -
-

Editors demo

- -
-

Table layout

- -
-

Various widgets, vertical and horizontal layouts

- -
-

Animation, i18n, theme with bigger fonts and dark main menu

- -
- -