Skip to content

Cross-platform Stride.Launcher#3027

Open
Kryptos-FR wants to merge 51 commits into
masterfrom
feature/launcher-avalonia-cherrypick
Open

Cross-platform Stride.Launcher#3027
Kryptos-FR wants to merge 51 commits into
masterfrom
feature/launcher-avalonia-cherrypick

Conversation

@Kryptos-FR

@Kryptos-FR Kryptos-FR commented Dec 30, 2025

Copy link
Copy Markdown
Member

PR Details

New Launcher using Avalonia instead of WPF. Still needs some love.

Related Issue

#1503

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My change requires a change to the documentation.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have built and run the editor to try this change out.

@Kryptos-FR Kryptos-FR added the area-Launcher Stride Launcher label Dec 30, 2025
@Kryptos-FR Kryptos-FR force-pushed the feature/launcher-avalonia-cherrypick branch 3 times, most recently from 7b72320 to 03f94a4 Compare December 30, 2025 18:49
/// Returns path of Launcher (we can't use Assembly.GetEntryAssembly().Location in .NET Core, especially with self-publish).
/// </summary>
/// <returns></returns>
internal static string? GetExecutablePath() => Environment.ProcessPath;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: Could this property not be used directly?

@Kryptos-FR Kryptos-FR Jan 5, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I just replaced code from the previous implementation to make it cross-platform without changing the overall structure. We could inline it manually.

On the other hand, the method name is a bit more explicit. It's likely inlined anyway by the compiler, so it's just a matter of preference.

}

// Avalonia configuration, don't remove; also used by visual designer.
public static AppBuilder BuildAvaloniaApp()

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: This method seems to be unused. It would be great to integrate with RunNewApp somehow

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's used by the Avalonia plugin. It's needed for the designer.

@Kryptos-FR Kryptos-FR force-pushed the feature/launcher-avalonia-cherrypick branch from 03f94a4 to e96d938 Compare January 7, 2026 20:45
@Kryptos-FR

Kryptos-FR commented Jan 8, 2026

Copy link
Copy Markdown
Member Author

@Jklawreszuk I have merged back master to this PR's branch.

It's mostly working but it would be nice to also support (un-)installing the Stride packages on Linux even if we can't fully use it there yet.

Did you want to contribute to it? The branch is on this repo, so feel free to push commits if you want.

@Jklawreszuk

Jklawreszuk commented Jan 13, 2026

Copy link
Copy Markdown
Collaborator

I am sorry, but it took some time to review all the files.Overall, it looks great! A quite accurate implementation of the original Launcher. However, I have a few comments:

  • The ‘See release notes’ feature does not work - also an empty button is displayed. A hint that might be helpful - MarkdownScrollViewer.Markdown property is always null.
  • It would be nice to implement a custom title bar like in the original, but this can be done in a separate PR.

Other than that I didnt notice nothing unusual 😅

@Jklawreszuk

Copy link
Copy Markdown
Collaborator

@Kryptos-FR Once the changes have been merged, I will try to adapt Launcher to Linux if necessary. But I think that installing/uninstalling packages works correctly, no?

@Kryptos-FR

Copy link
Copy Markdown
Member Author

I don't remember if it does work. I assume since it's restoring packages it should.

I guess we'll know soon.

@Kryptos-FR Kryptos-FR force-pushed the feature/launcher-avalonia-cherrypick branch from e96d938 to e161999 Compare April 7, 2026 20:55
@xen2 xen2 force-pushed the master branch 2 times, most recently from ab329f3 to 482bd28 Compare April 16, 2026 07:56
@Kryptos-FR Kryptos-FR force-pushed the feature/launcher-avalonia-cherrypick branch from e161999 to 4950387 Compare April 21, 2026 15:19
@Kryptos-FR Kryptos-FR marked this pull request as ready for review April 21, 2026 15:20
@Jklawreszuk

Copy link
Copy Markdown
Collaborator

@Kryptos-FR Have you tested it on Windows? It seems to work fine on Linux. They only issue I see is the empty button in the release notes page
image

Kryptos-FR and others added 6 commits April 25, 2026 07:31
Complete the launcher README with build, versioning and layout notes, and
add a hub-and-spoke documentation set under docs/launcher/ covering
architecture, view models, views, version management, self-update,
settings, localization, packaging, lifecycle and cross-platform notes.
Captures the full delta between the current Avalonia branch and the WPF
launcher on master — including silent regressions that are not marked
with TODO/FIXME — and a phased roadmap to close the gap for
cross-platform parity. Notes Stride.Metrics and PrivacyPolicyHelper as
deliberate, permanent removals.
…ncher port roadmap

Adds a test-infrastructure phase covering bootstrap of Stride.Launcher.Tests,
view-model and Avalonia-headless integration tests, and CI wiring for both
Windows and Linux.
Kryptos-FR added 3 commits May 2, 2026 23:25
… right-click offset

Right-click events on the Button inside each row were not reliably bubbling up
to the outer Border's ContextMenu on Linux. Moving the ContextMenu to the Button
directly — and adding VerticalAlignment="Stretch" — ensures the menu opens wherever
the row is visually hit-tested.
- Mark 'Show in Explorer' as fixed (cross-platform since commit c2555d0):
  update 'already ported' bullet and strike through the regression entry
  with the three-platform implementation detail
- Correct slide animation duration from 0.5s to 1s in both the Fixed
  description and the Phase 3 roadmap entries (1s was intentional)
@xen2

xen2 commented May 15, 2026

Copy link
Copy Markdown
Member

Looking at PR desc:

Still needs some love.

I wasn't sure, Is it ready for review or still WIP?
Otherwise, let me know when it is!

@Kryptos-FR

Copy link
Copy Markdown
Member Author

I would say, it is ready for review and testing on both Windows and Linux. I think I have one or two small fixes to push that I did on another branch.

- Add cross-platform IPC: Windows HWND broadcast + Linux named pipe
- Update launcher documentation (port-status.md, cross-platform.md)
- Add editor selector ComboBox to choose between WPF and Avalonia GameStudio
- Auto-install companion editor package (WPF/Avalonia) after primary install
- Query NuGet store directly for installed editor paths (works across sessions)
- Persist preferred editor choice in launcher settings
- Add EditorNameConverter for friendly display names
- Disable editor/framework selectors during install
- Update launcher documentation (port-status.md)
On Linux (and other non-Windows platforms):
- CanStart requires the Avalonia editor to be present; Start button stays
  greyed out for versions that only have a WPF (Stride.GameStudio) package.
- UpdateAvailableEditors re-evaluates CanStart after editor discovery,
  since UpdateStatus runs before AvailableEditors is populated.
- EditorNameConverter returns 'Game Studio' without '(Avalonia)' qualifier,
  as there is no WPF alternative to distinguish from.
- TryInstallCompanionsAsync skips the Stride.GameStudio (WPF) companion
  install on non-Windows platforms.

The EditorSelector ComboBox is already hidden when AvailableEditors.Count <= 1,
so the dropdown never appears on Linux.

@Jklawreszuk Jklawreszuk left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would say that LGTM! It's great that you added the documentation - it'll be useful to anyone who wants to revisit the code. As for the Launcher, I haven't noticed any significant visual glitches or anything like that.
What I tested on Linux:

  • Installing/Uninstalling multiple instances of GameStudio - works as intended
  • Including installing xenko versions - works ? (However, xenko is located in .../stride/sources/launcher/Stride.Launcher/bin/Debug/xenko/version/xenko.version.nupkg)
  • Clicking in all the urls, release notes - works

@Kryptos-FR

Copy link
Copy Markdown
Member Author

I'll admit I didn't try to install any Xenko versions. I'll look at it.

@Kryptos-FR

Copy link
Copy Markdown
Member Author

The right question should actually be: do we still want to include any older Xenko versions in the launcher? It's not open-source and very obsolete. cc @xen2

@xen2

xen2 commented May 24, 2026

Copy link
Copy Markdown
Member

I would say, not necessary anymore.
We can get rid of those last vestige from the codebase.

- Drop all Xenko package references (Names.Xenko, GameStudioNames.Xenko,
  MainPackageIds entries for Xenko/Xenko.GameStudio) since backward
  compatibility with pre-Stride packages is no longer needed
- Simplify PackageFilterExtensions to only match Stride.GameStudio and
  Stride.GameStudio.Avalonia.Desktop
- Remove CheckDeprecatedSourcesCommand (prompted users to add the old
  Xenko NuGet source) and its AskAddNugetDeprecatedSource string resource
- Remove old Xenko executable fallback paths from StrideVersionViewModel
- Remove the 'Show/Hide beta versions' toggle button: it existed solely
  to surface old Xenko (major < 3) packages; with those gone the button
  had no effect. Removes ShowBetaVersions, IsBeta, IsBetaVersion, the
  toggle button AXAML, and the ToggleShowBetaVersions/ToggleHideBetaVersions
  string resources
- Update NugetStore.MainPackageIds to include Stride.GameStudio.Avalonia.Desktop
- Update launcher README
Update all docs under docs/launcher/ to match the code changes:
- cross-platform.md: remove Xenko.GameStudio.exe from Windows fallbacks
- lifecycle.md: remove Bin/Windows/Xenko.GameStudio.exe legacy path
- README.md: s/Stride\/Xenko versions/Stride versions/
- versions.md: remove 'Beta filter' section (ShowBetaVersions / IsBetaVersion),
  update StrideStoreAlternateVersionViewModel description, remove Xenko.GameStudio.exe
  mention, update RemoveUnusedPackages description
- viewmodels.md: remove IsBeta from StrideVersionViewModel description,
  remove 'e.g. legacy Xenko ID' from StrideStoreAlternateVersionViewModel
- port-status.md: remove ShowBetaVersions toggle bullet
Replace the verbose in-progress tracking doc with a focused reviewer
reference. Drop all resolved regression history and done roadmap items.
Keep only:
- What's ported (brief feature list)
- Deliberate changes table (so reviewers don't revert intentional choices)
- Open items: .NET 10.0 probe decision + post-merge future work
- Cross-references
@Kryptos-FR

Copy link
Copy Markdown
Member Author

@xen2 I removed references to Xenko and updated the related documentation (under docs/launcher).

@xen2

xen2 commented Jun 3, 2026

Copy link
Copy Markdown
Member

Still needs some love.

I wasn't sure if this was now ready for final review/test/merge? (otherwise feel free to mark as draft)

@xen2

xen2 commented Jun 25, 2026

Copy link
Copy Markdown
Member

Still needs some love.

I wasn't sure if this was now ready for final review/test/merge? (otherwise feel free to mark as draft)

@Kryptos-FR so was this ready for merging?

@Kryptos-FR

Copy link
Copy Markdown
Member Author

@xen2 it's ready for final review and merging, assuming we fix the conflicts.

Resolve launcher (Avalonia) vs WPF conflicts; take master's xunit runner; add Stride.Cli to launcher solution; implement multi-checkbox dialog for Avalonia.
@xen2

xen2 commented Jun 29, 2026

Copy link
Copy Markdown
Member

@Kryptos-FR I did a merge from master, don't hesitate to check if anything looks wrong.
I tried to run it and it was OK.

@Kryptos-FR

Kryptos-FR commented Jun 29, 2026

Copy link
Copy Markdown
Member Author

@xen2 there are a couple of build issues. I will fix them.

edit: fix the build issues in .cs code caused by the merge. However I now get a error MSB4057: The target "GetTargetPath" does not exist in the project which was supposedly fix by 64012d0. This happens for any Stride.Templates project from Visual Studio, also on master.

@Kryptos-FR Kryptos-FR force-pushed the feature/launcher-avalonia-cherrypick branch from 9c29b2e to 11559ae Compare June 29, 2026 19:05
@Kryptos-FR

Kryptos-FR commented Jul 5, 2026

Copy link
Copy Markdown
Member Author

@xen2 merged master and fixed the conflicts. I wondering if the Launcher should also be optionally installed through the Stride CLI (stride launcher install)? Or in other words, do we still need the custom installer?

@xen2

xen2 commented Jul 8, 2026

Copy link
Copy Markdown
Member

I wondering if the Launcher should also be optionally installed through the Stride CLI (stride launcher install)? Or in other words, do we still need the custom installer?

I was also hesitating about that.
I was thinking we still wanted a proper .msi installer with CLI and an uninstall entry? But not sure about it...

I think first we want to decide how we distribute the launcher in the future:

  • do we want launcher itself to become a dotnet tool?
  • if yes, what does the actual installer do? install a precompiled version in program files (better control over uninstall), or simply get it installed as global dotnet tool in default folder? or dotnet tool with custom location in program files?

@Ethereal77

Copy link
Copy Markdown
Contributor

Imo the Stride CLI is reasonable as a .NET tool, as it is going to be used by programmers used to work with the console. However, the launcher is more oriented towards the general public, and requiring someone that only wants to try Stride to go to the console to write commands is a barrier many people won't pass through.
For those people. the experience of an installer or a bootstrapper is more welcoming.

Another issue some people have (although it is minor imho) is that Stride is not "installed" in the usual sense, but downloaded and referenced from the NuGet cache. I've talked with several people that have used other engines and find this highly confusing (specially if they are not very versed in NuGet).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-Launcher Stride Launcher

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants