D language for Graphical User Interface and Cross Platform Development
Виталий Фадеев
vital.fadeev at gmail.com
Mon Jun 29 14:34:45 UTC 2020
On Monday, 29 June 2020 at 13:14:04 UTC, Виталий Фадеев wrote:
> On Sunday, 28 June 2020 at 18:01:08 UTC, c-smile wrote:
>> On Thursday, 25 June 2020 at 20:42:25 UTC, Robert M. Münch
>> wrote:
>>> On 2020-06-25 03:33:23 +0000, Виталий Фадеев said:
>>>
>>>> What about Sciter ?
>>>>
>>>> Site: https://sciter.com/
>>>>
>>>> D: https://github.com/sciter-sdk/Sciter-Dport
>>>
>>> It looks interesting but I never tried it. Any experience
>>> with it?
>>
>> Sciter's author here.
>>
>>
>> If to consider a "perfect and modern D GUI library":
>>
>> 1. It should have unified DOM serializable to HTML/XHTML.
>> There are many good reasons for that, from Accessibility
>> (a.k.a. Section 508), to things like enabling React alike
>> functionality and JSX. D syntax may even support JSX natively
>> in the way I did in Sciter's script:
>> https://sciter.com/docs/content/script/language/ssx.htm
>>
>> 2. It should be style-able, so is CSS or its subset. It is
>> again flexible and 95% UI developers know it already.
>> Style-ability here means not just colors but flexibility and
>> configurability of element flows (layout manager in Java AWT
>> terms).
>>
>> 3. It shall use GPU rendering as much as possible. That's the
>> must for high-DPI monitors.
>>
>> 4. Implementation shall be compact - each D GUI application
>> will include it statically and compilations time shall be
>> short.
>>
>
>> Please let me know if someone will start doing anything close
>> to the the above in D - I can help.
>
In first version was GC. It gived many time for experiments. GC
take on self dirty work.
Now Node/Element will like this:
struct Node
{
Node* parent;
Node* firstChild;
Node* lastChild;
Node* prev;
Node* next;
}
struct Element
{
Node node;
alias node this;
//
Properties props; // Element properties
Properties style; // Style properties
//
Computed computed; // <-- after Apply Style and Update.
Initial Properties + Style Properties + Element Properties
//
Node* g; // Window
//
Eventer!( MouseEvent ) onMouseMove;
Eventer!( MouseEvent ) onMouseButton;
Eventer!( KeyEvent ) onKey;
Eventer!( ClickEvent ) onClick;
Eventer!( SizeEvent ) onResize;
//
uint updateStamp;
}
Robert ( c-smile ),
1. How you see best Node / Element structure ?
More information about the Digitalmars-d
mailing list