Delta Engine
»
Support
»
UI
»
Binding controls made in UI editor
Joined: 12/26/2013(UTC) Posts: 11 Location: New Mexico
|
So, I'm trying to set up some UIs with the editor, to make the job of previewing them nice and easy, but i'm coming into a problem - I can't seem to grab the controls via name in code. I can easily grab by index, but this leaves little maintainability when I want to add buttons or such later. Is this on purpose? Or am I missing something to do with the Names each control is given?
Assuming I'm not missing something, I plan to once again modify the base engine to support this, so a heads up or any advice there will also be appreciated n.n
|
|
|
|
Joined: 8/23/2011(UTC) Posts: 245
Thanks: 6 times Was thanked: 12 time(s) in 11 post(s)
|
A similar issue was raised only a few days ago :) http://forum.deltaengine...719_Scenes.aspx#post6002Ben says there's a number of suggestions floating around to do with Scenes - so please feel free to add anything into the mix you'd like to see: ie. How it could be made more useful/user-friendly for you or how you'd go about improving things.
|
|
|
|
Joined: 12/26/2013(UTC) Posts: 11 Location: New Mexico
|
Biggest usefulness is names - a close second would be an easier time loading a scene from a derived class, so as to put the code that sets up bindings with the content itself, as I'm trying to do as we speak. This could eventually go as far as making code-generation for the UIs and having users define partial classes - though that I see as being a long, long way off.
|
|
|
|
Joined: 12/31/2013(UTC) Posts: 11 Location: Enschede
Thanks: 2 times
|
Would it be possible to store the scene in some kind of XML (or text) format? This way developers could add it (as link) to a solution and use a T4 template to generate typed code. The benefit is that this gives compiler errors when something in the scene changes that should not have been changed.
One other thing that got into my mind was to reverse the whole binding, just like MVVM and comparable technologies work. Somehow such an approach just works.
Also, the UI scene designer could use some undo/redo functionality and seems to have some weird quirks when reconfiguring a scene or when saving/renaming items.
Just my two pennies...
Regards and keep up the great work,
Peter Vrenken - Atos
|
|
|
|
Medals:  Joined: 8/20/2011(UTC) Posts: 1,421 Location: Hannover
Thanks: 18 times Was thanked: 97 time(s) in 92 post(s)
|
We had a much more verbose format in older versions of the Delta Engine and switched to a binary format (custom) in v0.9.x, later in v0.9.7 the BinaryData was used and it made a ton of code and maintaining UI controls a lot easier. However there were a lot of changes in controls, which did not go through the version numbering of scenes and some mistakes where made, so the mess is a bit bigger than it should have been.
Maybe some kind of mixed solution would be useful. Each class saves its data and if anything changes just some fields are not set, or one single control does not work anymore while the rest of the scenes loading still works fine. We should be able to improve the BinaryData system easily to accommodate this (btw: writing out into Xml data from there is also not very difficult, just a few methods would have to be overwritten, the rest of the logic can stay the same way).
|
|
|
|
Delta Engine
»
Support
»
UI
»
Binding controls made in UI editor
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.