3 ms·
It's not good D.R.Y. to reinvent a binding library for each and every application language. What's needed is a state-ful GUI markup standard. Then any language
by tabtab 4y ago
It's not good D.R.Y. to reinvent a binding library for each and every application language. What's needed is a state-ful GUI markup standard. Then any language that can emit and read XML can use the GUI kit/browser/component, no binders needed.
- 13415 4y agoWhat's the advantage? This merely seems to add another layer of abstraction.
- JasonFruit 4y agoThat way, your language can use any toolkit, such as WebKit or Gecko.
- Spivak 4y agoWhat you're describing is GObject inspection. It's literally a series of XML documents that can be used to autogenerate ffi bindings in any language. The future is now.
- nerdponx 4y ago...which is literally what these Lisp bindings use.
- spicybright 4y agoIf you did that, you limit what the API of a framework can do, you either can't use ones that fall outside that spec, or you have to jump through hacky hoops to get it working. Experienced engineers know D.R.Y. has it's uses, but isn't a good hill to die on.
- pavon 4y agoNo one will want to write GUI code that directly parses and generates XML, so every language will end up putting wrappers around that, and you are back to where you started with an expensive translation layer in-between. Having a machine format that describes the interface and facilitates auto-generating the bindings, like GObject introspection is a better option and exists today. Even then the auto-generator will need to be custom for each language, to handle integration with the language's standard library data structures, memory management and the like.
- carapace 4y ago> XML User Interface Language is a user interface markup language developed by Mozilla. XUL is an XML dialect for writing graphical user interfaces, enabling developers to write user interface elements in a manner similar to web pages. https://en.wikipedia.org/wiki/Xul https://en.wikipedia.org/wiki/Xul
- bmitc 4y agoI'm not sure DRY applies across language boundaries. If a binding exists in one language, creating a binding in another isn't really repeating anything.