Ask HN: What's wrong about Windows/macOS/GNU-Linux as of now? - bhnmmhmd
======
Someone1234
This issue dates all the way back to the late 1980s but...

On Windows, at some stage, it was decided to allow one application to steal
user focus from another application. That was a bad design decision, but one
that it might be too late to undo, even Microsoft's own software relies on the
ability to shift focus onto some inane popup.

To use an analogy, imagine how you'd feel if on Android/iOS you were in one
app and without warning another app just started and took focus. You'd be
super mad. But on Windows that is so common we have blinders on to it.

There's a particularly obnoxious bug still in Windows today related to this.
If the iTunes or Java background update task kicks off, you'll never see it,
but it will shift keyboard focus to nothing. Visually it causes a slight
flicker, but if you type the keypresses go nowhere since focus shifted to a
now closed window (a window that was open for less than a second).

Even Windows UWP apps aren't immune. While one UWP app cannot easily steal
focus from another, Win32 API applications (and Windows' own processes)
continue to steal focus. Applications that want focus should just blink on the
taskbar, focus should only change when the user changes it.

Microsoft thinks they fixed this (see SetForegroundWindow[0]):

> An application cannot force a window to the foreground while the user is
> working with another window. Instead, Windows flashes the taskbar button of
> the window to notify the user.

But for whatever reason the issue remains. Particularly the keyboard input
disappearing into null behavior I described above.

[0] [https://msdn.microsoft.com/en-
us/library/windows/desktop/ms6...](https://msdn.microsoft.com/en-
us/library/windows/desktop/ms633539\(v=vs.85\).aspx)

~~~
Jasper_
Part of this is that UI toolkits do more and more disgusting things in order
to preserve this behavior. Windows allows the foreground window to activate
other windows "owned by the same app" so that existing applications don't
break. The implementation, for this, of course, is a pile of heuristics [0].

Qt, steadfast in its duty to be as annoying as possible, pretends it is part
of the foreground app when you call activate() by calling AttachThreadInput
[1].

[0] Documented heuristics, even. [https://msdn.microsoft.com/en-
us/library/windows/desktop/ms6...](https://msdn.microsoft.com/en-
us/library/windows/desktop/ms633539\(v=vs.85\).aspx) [1]
[https://github.com/qt/qtbase/blob/5.11/src/plugins/platforms...](https://github.com/qt/qtbase/blob/5.11/src/plugins/platforms/windows/qwindowswindow.cpp#L2194-L2209)

------
psyc
Windows 10: Default experience is terrible, and customizing it is a full-time
job. Update is hostile (interrupts work) and buggy (can bring down the whole
system). Every advertisement in the start menu must be removed manually,
afaict. Notifications are annoying almost beyond belief. Common settings,
especially pertaining to users and permissions, are spread to more obscure
system apps than ever. Control Panel Lite is inadequate and just adds
confusion on top of Control Panel Classic. Windows UI has the same basic
painting bugs that have existed forever, where you have to jigger things
around to make them visually refresh. Exhortations to use Edge browser are
more annoying and hostile than ever, and some system functions force Edge
instead of the default browser.

------
limeblack
Linux differences between distributions make packing one binary basically
impossible especially when trying to implement GUIs. This almost gets
hilariously bad having companies package their multiple GBs binary software as
.sh scripts that install different packages & extract depending on the distro.

Linus Torvalds said in one of his talks that it is his belief why GNU-Linux on
the desktop hasn't taken off.

------
klez
I would suggest you expand a bit on what kind of things you're looking for, or
at least give a reason for this kind of question, so as to limit the topic.
Because as it stands, this question risk becoming flamebait in no time.

------
stealthcat
GNU Linux userland/desktop lacks BDFL. No one is enforcing one right way to do
things, hence distros fragmentation.

------
asicsp
they make doing cross-platform applications difficult/bloated

------
Piskvorrr
Yes. And Android/iOS.

