Live data from Hacker News

Windows Code Samples

microsoft.github.io

31–40 of 107 posts

Re: Windows Code Samples

#31
post #14

Earlier quoted context omitted.

Open source doesn't mean free....

Be realistic, the next day 10 forks would appear distributing it for free.

Windows is always pirated distributed for free doesn't mean they don't violate copyright laws and other restrictions.

One can buy an oem or restricted region license for windows for 20$ but legally it's about the same as pirating it.

Re: Windows Code Samples

#32
post #4

I really hope they open source the NT kernel, or at least part of it. This makes me really excited about the future of Windows!

Some institutes at some universities have access to the NT source code for academic purposes. (Google "Windows Research Kernel" -- supposedly some academic entities have more access).

Governments also have access to the source code for many msft products including windows.

Trusted partners that develop for windows and oems can also gain access.

Re: Windows Code Samples

#33
post #4

I really hope they open source the NT kernel, or at least part of it. This makes me really excited about the future of Windows!

That would be an interesting concept. NT is a powerful operating system, but without the Windows Subsystem, it would be useless except as a drop-in replacement on Windows installations.

This idea is probably more feasible than first glance would suggest, but still, I wouldn't hold your breath.

Re: Windows Code Samples

#34
post #22

Earlier quoted context omitted.

Depends on your use case/tools/habits. WSL gives you the advantage of being able to access the same files with native Windows tools and from the GNU[1] command line. If you plan on using the X GUI tools, it will be much less useful to you. [1] I can't bring myself to use the term 'Linux' here, because, ironically, Linux is the primary missing part in this Ubuntu distribution. It should really be called WSG or WSU.

All of my friends on windows say X is just as easy to set up as on cygwin

I never said X GUI apps could not be used, just that the more Windows tools you use, the more you gain more from WSL.

Re: Windows Code Samples

#35

Earlier quoted context omitted.

If you plan on using the Linux GUI tools, it will be much less useful to you. If you install an X server, such as VcXsrv and set the DISPLAY variable (typically export DISPLAY=:0 will suffice), you can just run X11 apps. For instance, here's a screenshot of a Prolog/Tk application running on WSL: https://danieldk.eu/Posts/2017-01-10-Alpino-Windows/alpino-w... I have installed Windows on a workstation just to try WSL…

So if I want to use my GPU for machine learning applications, I would have to run my programs under Windows rather than from inside the WSL?

Indeed. There is a 'uservoice' about this issue:

https://wpdev.uservoice.com/forums/266908-command-prompt-con...

Re: Windows Code Samples

#36
Here's the problem: As a developer Electron (see http://electron.atom.io/ ) is more attractive to me than Windows APIs. Take a look at the RSS Reader ( https://github.com/Microsoft/Windows-appsample-rssreader ). I can make a desktop app that is practically indistinguishable from this app using Electron, so why would I use Windows APIs? If I use Electron then my app will run on Mac and Linux, not just Windows, and my skills will be portable too.

The Flat UI of Windows is a mistake. Because of Flat UI, there is no differentiation between Web apps and native Windows apps, which makes it possible--and even desirable--to make desktop apps using Web technologies.

Re: Windows Code Samples

#39

Here's the problem: As a developer Electron (see http://electron.atom.io/ ) is more attractive to me than Windows APIs. Take a look at the RSS Reader ( https://github.com/Microsoft/Windows-appsample-rssreader ). I can make a desktop app that is practically indistinguishable from this app using Electron, so why would I use Windows APIs? If I use Electron then my app will run on Mac and Linux, not just Windows, and my…

We had to redo an inhouse Electron app in WPF because we came to the point where we had to do some stuff within windows, e.g. printing or create a heavily customized MSI file. Both is possible with Electron but with the native Windows solution it's easier to fine-tune behavior.

I think for UI and some web stuff Electron might really be superior. Especially if your team is already fluent with the web stack. But it has it's limits and if you reach them or have very specific requirements you might be better of with WPF or UWP apps and the initially higher effort of developing in C#/XAML might pay off.

Saying this I believe the existence of Electron is a great possibility for UI devs.

Re: Windows Code Samples

#40

Here's the problem: As a developer Electron (see http://electron.atom.io/ ) is more attractive to me than Windows APIs. Take a look at the RSS Reader ( https://github.com/Microsoft/Windows-appsample-rssreader ). I can make a desktop app that is practically indistinguishable from this app using Electron, so why would I use Windows APIs? If I use Electron then my app will run on Mac and Linux, not just Windows, and my…

- Electron is big dependency, adding hundreds of MB to our app

- Electron Apps haven't and won't ever 100% fit into the OS environment/theme, neither Windows, macOS, or any Linux desktop

- Electron takes a long time to start up

- Electron eats a big amount of memory

- Electron uses a lot more battrey

- Many APIs of the underlying OS are not avaiable to Electron, especially those not found on competing platforms

So, allow me to say this: If web technologies are more attractive to you (which is completely fine), stick to the web. But don't create Desktop programs that waste ressources and time just for the sake of having "a true cross platform app".

Post reply on HN