In the recent thread about reinventing wheels, a popular theme was trashing C++. Another theme that emerged was a graphical code editor that uses XML. This will be the thread about the machine readable/writable XML format.
The Java source now compiles with Ant. The only modifications needed were that the 1.3 compiler version had to be updated to Java7, and there are obviously deprecation notices but it still works. Hosting is at https://github.com/SamuraiCrow/oXML and CI is active.
I was thinking of modelling the syntax of the new transpiler backend around C++17 using Svelte as a model. Now I’m beginning to wonder if that’s the best way. It’ll work, but my concerns are starting to shift from the graphical editor to the XML language its based on. A graphical development environment is only as strong as its foundation.
I’m looking at Svelte because its compiler-driven approach to GUI development is not based on a fancy object-oriented framework. If I made it work on future operating systems, the code generator would have to be changed anyway. If I used an OO framework instead, it would have to shift the implementation to the runtime library and would be slower and would require the same amount of work for every new OS regardless.
Are there any web devs here that can comment on Svelte and how it stacks up?
Back in my college years I attended a few ACM meetings and during the XAML demonstration, the presenter showed how to embed a browser in a drop-down menu. I don’t think Haiku can (or should) do that.
In summary, promoting a web-view to a first-class gadget is not going to fly; not on my watch. Consider the Microsoft bloat-ware to be persona-non-grata on my desk.
I’m a little confused: XAML is just a serialization format. For example, I’ve use XAML to create a generic menu structure before, the XAML was loaded at runtime and the menu structure was built from the data. When you instantiate XAML, you end up with a bunch of class instances. The serialization works a lot like SVG or the way the AXML works in Android. There is nothing like what you are saying unless you are trying to do something silly. Here is a Be API specific pseudo code example:
No web browsers, no web. This would literally just instantiate a BWindow with a BView and a BButton. I think you might need to actually derive from those classes because they don’t lend themselves to injecting data quite in that way, but the event mechanism can be added. I did this back in the day when I was playing with Free Pascal and making UI for that in the Style of the Delphi API (also event driven.)
Remember - XAML is a markup, XAML is used to represent concrete classes in a serialized format, it is nothing to do with the deserialized version - that is implementation specific. XAML is used by a lot of technology now, WPF, UWP, WinUI, Maui, Xamarin Forms, UNO, Avalonia - a lot of those are cross platform. XAML doesn’t even require you to use any specific classes or implementation - the serializer/deserializer on the platform deals with working out how the markup maps.
I must have been thinking of WinForms. Since that is only an application of XAML and not XAML itself, I’ll reconsider your advice. Your earlier 2 links indicated Boost dependencies and one mentioned a WebView as a dependency.
Whether XAML is compatible with Relax-NG or any other parser schema outside of Mono/.Net is another consideration. .Net has some visual language capabilities already via 3rd party add-ons and can be used instead of any less-integrated, modular library but I don’t want to drag in excessively large dependencies. Having never used Microsoft products on a regular basis, I’d prefer to keep it that way.
After looking at the Haiku Book closely, I’m beginning to wonder if it would be possible to make a BViewToXML class that inherits the BFlattenable interface that would use the product of a BMessage like you just suggested. That way the resultant XML could be treated like a resource and just edited externally with an updated ALE app (possibly renamed HALE to differentiate it from the original. ). The idea of using an editor for a GUI isn’t new, Apple does it with the XIB format, but it would save a UX developer the time of having to write a new export engine every time a new language comes out or a new InterfaceKit version the next time the winds of change hit the UX sector of the industry.
I never saw this page about layouts before. This may affect my decision.