News for hackers. Stuff that matters.
Re:.NET Standard 2.1 by maxxxxx on Monday November 05, 2018 @01:56PM (#18384872)
I do mainly desktop dev but reading that Core is now the platform with rapid improvements I wonder if it's possible to write WPF or UWP apps with .NET Core or Standard.

Does anyone know?

Re:.NET Standard 2.1 by michaelwda on Monday November 05, 2018 @02:01PM (#18384919)
This is coming in .NET Core 3. Slated for Q1 2019 AFAIK. https://blogs.msdn.microsoft.com/dotnet/2018/05/07/net-core-...
Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @02:14PM (#18385032)
If WPF is coming in .NET Core, does this mean we are going to be able to run WPF apps on Linux and Mac?
Re:.NET Standard 2.1 by algorithmsRcool on Monday November 05, 2018 @02:22PM (#18385095)
Nope, it will be a windows only capability.

-Edit-

I should add that the purpose of them adding this capability isn't to set up a new cross-platform UI suite. It is just to lure enterprise shops to .NET core by supporting more of their .NET Framework workloads

Re:.NET Standard 2.1 by solarkraft on Tuesday November 06, 2018 @02:33AM (#18389084)
I'm still wondering whether it would be smart for them to port WPF or UWP to all platforms. They are already decoupling their services from Windows and a UI library would be quite a flagship for them.

Then again they'd also lose the Windows vendor lock-in, which might still be more valuable to them.

Then again they could sell their development toolchain and gain developer sympathy.

Re:.NET Standard 2.1 by algorithmsRcool on Tuesday November 06, 2018 @11:36AM (#18392513)
Well, I think it is an engineering problem. WPF is basically cemented to DirectX which only exists on Windows.
Re:.NET Standard 2.1 by simonh on Monday November 05, 2018 @08:04PM (#18387488)
There will be a desktop pack that extends Core with windows desktop application technologies. Bear in mind these are really .NET API wrappers round the underlying Windows systems, so since those underlying libraries and such don’t exist on Mac or Linux .NET APIs won’t have anything to provide access to.

Think if it this way. Someone could write a .NET Core wrapper round the MacOS GUI libraries and platform APIs, but you couldn’t run that on Windows.

Re:.NET Standard 2.1 by maxxxxx on Monday November 05, 2018 @02:18PM (#18385062)
I highly doubt it. As far as I know WPF is way too entangled with Windows.
Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @02:21PM (#18385088)
But isn't .Net Core meant to be cross-platform?
Re:.NET Standard 2.1 by SemiNormal on Monday November 05, 2018 @02:31PM (#18385163)
It is. The WPF library is just a separate package that includes a lot of Windows API calls to allow .NET Core to talk to WPF.
Re:.NET Standard 2.1 by WorldMaker on Monday November 05, 2018 @04:11PM (#18386014)
In general, yes, but a lot of its cross-platform capabilities are community-contributed/community-led, there are still some APIs that don't have cross-platform implementations (because it hasn't been a community priority), but also there are APIs that simply can't work on any platform but Windows (obvious things like Registry access, for instance) and will either no-op or throw clear exceptions on other platforms.

The "desktop app packs" for WPF and WinForms Microsoft has made very clear that they will not support anything other than Windows. (They also won't directly be a part of .NET Core according to diagrams, but packages installed on top of it.) It's also unclear if they can be open sourced (they probably cannot be), and if they can't be open sourced it is unlikely a community-led effort could easily work on making them cross-platform.

Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @04:51PM (#18386309)
> The "desktop app packs" for WPF and WinForms

WinForms work quite nice on Linux with Mono. Won't they cooperate?

Re:.NET Standard 2.1 by WorldMaker on Tuesday November 06, 2018 @11:28AM (#18392418)
They might not port Mono's WinForms to .NET Core? Given how strictly tied to Windows WinForms is, they may not want to give enterprises they are encouraging to use .NET Core any confusion on the subject. Taking that extra step of trying to run the application on Mono shows at least some awareness of possible compatibility issues in the software.

That said, this may still be a great opportunity for .NET Core to encourage trying Mono in its documentation for enterprises looking for cross-platform support. (Hopefully they already knew about Mono by this point, but an extra push won't hurt.

Re:.NET Standard 2.1 by maxxxxx on Monday November 05, 2018 @05:03PM (#18386383)
I think Mono Winforms is a total rewrite of the Windows Winforms. There is no shared code.
Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @05:38PM (#18386649)
Sure it is but why not use that code to let .Net Core support WinForms on Linux the way it is going to support it on Windows?
Re:.NET Standard 2.1 by maxxxxx on Monday November 05, 2018 @05:59PM (#18386785)
I think you have that a little backwards. This is not up to the Core developers but to the Mono developers. There is nothing preventing the Mono developers from supporting .Net Core.
Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @06:33PM (#18386970)
Aren't these the .Net Core developers who sort of import (or re-implement?) WinForms support from the classic .Net Framework on Windows?
Re:.NET Standard 2.1 by hornetblack on Monday November 05, 2018 @05:55PM (#18386771)
It's shared with WINE I believe. (The native parts)
Re:.NET Standard 2.1 by qwerty456127 on Monday November 05, 2018 @06:35PM (#18386980)
Wine uses its own Mono instance and I usually run WinForms apps directly with the system Mono set-up without using Wine (although I have both installed).
Re:.NET Standard 2.1 by maxxxxx on Monday November 05, 2018 @02:07PM (#18384968)
Very good. For a moment I was worried that desktop development would stay on Framework which from the article seems to slowly being pushed into maintenance mode.
Re:.NET Standard 2.1 by Nelkins on Monday November 05, 2018 @02:10PM (#18384995)
Not WPF per se, but if you're looking for something similar check out https://github.com/AvaloniaUI/Avalonia
Re:.NET Standard 2.1 by rpeden on Monday November 05, 2018 @03:25PM (#18385617)
Xamarin Forms also has WPF, OSX, and GTK renderers, so it might be an option. Based on GitHub activity it looks like they're being worked on fairly actively, too.
Re:.NET Standard 2.1 by pknopf on Monday November 05, 2018 @04:49PM (#18386291)
You can also use QML with .NET Core.

https://github.com/qmlnet/qmlnet

It is stable, I'm currently using it in production (https://medxchange.com/4klear-all-in-one-camera-recorder/)

PS: I'm the author.