The State of the GUI

Guillaume Piolat spam at smam.org
Wed Oct 24 12:30:07 UTC 2018


On Wednesday, 24 October 2018 at 06:20:05 UTC, Adam Wilson wrote:
> So why doesn't D have ANY useful bindings UX library bindings?
>

There are: https://github.com/DerelictOrg/DerelictCEF

> The underlying theme here is that it takes an enormous pile of 
> resources to make a good UX toolkit. D has never had the kind 
> of corporate backing that the other toolkits have. So it should 
> come as no surprise that large scale projects, like UX have 
> been unattainable to date.

Without too much resources to invest topdown it's about 
building-blocks that multiple individuals can create.

> The D community, for all it's wonderful attributes does not 
> have a "team" mindset. And this bears out if you audit 
> code.dlang.org. The projects are universally the herculean 
> efforts of one person, and occasionally a small number of 
> secondary contributors.

Indeed, but all it takes is that each individual separates its 
herculean efforts in sub-packages, decouple them, and publicize 
them so that harder and harder projects can be built on top (with 
respecting SemVer and not staying in 0.x.y).

It's only slightly harder and the project usually benefit from 
decoupling.

One of the problem is the DUB registry search doesn't work.

That's why a registry-global search of symbols is so important, 
and two people have one solution to this: Adam and Webfreak.


> This isn't the first time I've asked for help.


Honestly UI toolkits are indeed coupled, perhaps unnecessarily, 
and I think we could strive to find something much more "Design 
by Introspection":


color abstraction (eg: `std.experimental.color`) <= image 
abstraction (eg: `ae.utils.graphics`)
image abstraction <= image decoder (eg: `imageformats`)
windowing (eg: dplug.window or something stealing it and making 
it SDL-like) <= Canvas renderer (eg: `printed`)
Canvas renderer + open-methods/ECS <= widget library (for a UI 
you need widgets that don't depend to the rendering method, and 
that's an open-method problem)
layout-system (something CSS-like) <= widget-library

Every one of these packages can work without the others, and 
essentially is not so opinionated.

(Anything based on OpenGL would be hopeless I think. But anything 
GPU-based and not OpenGL need some kind of shader compiler which 
is also too much work. So I think for the purpose of practicality 
it can be left as an exercise)

This would give a very basic portable GUI, without forgetting our 
big DbI principles, and the BIG work would be to make all this 
modules work well with each other. For example libraries need to 
be maintained to newer compilers, bug fixed, major tag respected.






More information about the Digitalmars-d mailing list