Open Kryptos-FR opened 6 years ago
Hi there, I'm new to Stride (actually, I've never actually participated in an open-source project before this), and I'm interested in helping out. My coding experience is limited to programing business software, so I think that this issue would be a good fit for me as a starting point, since it doesn't seem to require technical knowledge specific to game engine development.
Would it be OK if I tried to solve this issue?
@dadofboi Yes, definitely! PRs are welcome!
Hi, I've been trying to look through the XAML files and whenever I try to view the Designer tab, I get this error. Everything works perfectly fine when building Stride though, or when I create another WPF project.
Is this a bug, or is it actually expected behavior? I'm not familiar at all with WPF so sorry if this is a trivial issue.
Edit: For reference, here are the error messages:
Editing the attributes causing the errors gave me this error instead:
Commenting out the Window.Resources node allow me the load the designer, but with other errors:
In complex WPF applications you can't really use the designer because there's a lot of dynamic parts to the views - depending on the data you're working on in the project. So you wouldn't be working with a designer but straight with XAML. While debugging you can use VS tools to select a part of the window (a control or panel) and show it in the visual tree view which can allow you to map it back to a line in the XAML file.
Thanks for the help! My company still uses WinForms (yeah, I know), so I had no idea this is how WPF works. In that case I'll spend some time learning about WPF and then try to tackle this issue again.
Hello, is it okay if I take a stab at implementing this enhancement?
Definitely, please do !
Been looking at this and I think I have a good understanding on this system and what needs to be done, but just in case I was hoping to get some feedback real quick:
Still have a few questions:
Thank you so much for the quick response! These help very much, and I look forward to implementing this!
I'll come back to you with some details. Remind me in a few days if I forget.
I am looking into saving the selected settings in the editor as a settings key in internalSettings.cs. The issue I am running into is how to access the ObservableList
@soorMSWE What are you trying to do specifically here, saving and restoring the assets that were selected in the last session ? If that's the case, best to avoid it for now since this is actually quite complex in comparison to what this issue is about. Not sure the settings serialization is prepared for that.
Hello,
I confused myself with what I was trying to do. I am actually trying to save the asset filters and not the selected assets. I am currently looking into it. Please let me know if you have any suggestions!
Hello,
I am currently looking at how to possibly put the current filters stored in ObservableSet
@soorMSWE
Are we able to save out the lists through the SettingsKeys?
Afaict, yes, we have tests covering those here https://github.com/stride3d/stride/blob/master/sources/core/Stride.Core.Design.Tests/TestSettings.cs And one actual usage over there https://github.com/stride3d/stride/blob/master/sources/editor/Stride.GameStudio/Settings/GameStudioInternalSettings.cs#L16
I was thinking maybe pulling out the stored strings in the AssetFilterViewModel objects and storing them in a settingsKey
Sounds good, just a note, there's also the FilterCategory Category
which should be saved alongside the string that way you can properly differentiate between name, tag and type filters.
If you create a new data type to store those two variables into, make sure to decorate it with [DataContract]
for it to be properly serialized. If you need more info on how the serialization works in this engine there's a fairly thin document over there https://doc.stride3d.net/latest/en/manual/scripts/serialization.html
Issues reserved for newcomers. Consider taking it only if it's your first time working on a feature or a bug in Xenko.
The view options (such as level of zoom, filters, grid or tile view, etc.) are not saved in the settings and thus use their default value when restarting the Game Studio.
Starting point:
AssetViewUserControl.xaml
inXenko.Core.Assets.Editor
EditorSettings
inXenko.Core.Assets.Editor
AssetCollectionViewModel
inXenko.Core.Assets.Editor