3 ms·
"lower-level cross-platform abstraction" needs some clarfication. For example Sciter exposes Graphics API https://github.com/c-smile/sciter-js-sdk/blob/main/in
by c-smile 5y ago
"lower-level cross-platform abstraction" needs some clarfication.
For example Sciter exposes Graphics API https://github.com/c-smile/sciter-js-sdk/blob/main/include/sciter-x-graphics.h https://github.com/c-smile/sciter-js-sdk/blob/main/include/s..., is this close to what you mean? It allows to render stuff a la ImGUI - immediate mode painting.
And what's in principle wrong with DOM?
DOM is tree of lightweight nodes and elements. In Sciter each DOM element may have native controllers, known as behaviors. Examples of those: https://github.com/c-smile/sciter-js-sdk/tree/main/include/behaviors https://github.com/c-smile/sciter-js-sdk/tree/main/include/b... . So you can create single DOM node - document and attach your native behavior to it. It will receive all events and will do drawing if you want.
Some applications are using mixed model: DOM where it makes sense, and custom native behavior where high performant handling is required.
In fact DOM and ImGraphics have their strong points but in different situations. Sciter allows to have best of two worlds by combining them.
In any case when you say "I don't need DOM", it means that you will implement it on your side. Been there, seen that many times.
- Sophistifunk 5y agoThanks for your reply. It's not that I don't want any DOM, it's that I specifically don't want "the" DOM as seen in web browsers. What I want is a scene graph without layout or CSS, but with events and transform nodes and the like. You can get close to this in web DOM just by making everything absolute and just not using CSS, but without a way to measure text before drawing it, you can't do your own layout properly. It looks like Sciter might be what I need to build on top of though, I will look into it further.