tsujan / Kvantum

A Linux SVG-based theme engine for Qt and KDE
1.58k stars 148 forks source link

Windows 10 version needed #476

Closed patlecat closed 4 years ago

patlecat commented 4 years ago

Can you pls create a version of Kvantum that does compile and run on Windows 10 and allow only to theme your own application and of course not the whole OS? I think that would be much appreciated by many devs. And this way we could simply use existing style/theme packages!

tsujan commented 4 years ago

I'm afraid I can't because I don't have Windows and I don't think it can be done for Windows by a simple patch. Moreover, if a developer does it, I couldn't test it.

Kvantum for Windows may be possible (without some features) but it might need a separate way of development, in which I couldn't participate.

patlecat commented 4 years ago

@tsujan Maybe you can't but it can be done. The port to Windows would only need the themeing core of kvantum. I haven't looked at your code but if you have done it professionally then the themeing part is decouples from the window management systems. Therefore that part could be ported alone, that would consist a huge boost for the millions of developers.

tsujan commented 4 years ago

Qt is Qt everywhere but there are lots of code related to X11 (or lack of it = Wayland), blurring and grabbing windows from inside them. As I said above, I can neither do it nor test it if someone else does it.

tsujan commented 4 years ago

Actually, it's also wrong to say, "Qt is Qt everywhere" — my bad. There are many places in Qt doc, where it's explained how Linux, MS Windows and macOS have different behaviors regarding this or that method. Also, there have been so many bugs that appear in Windows but not Linux, and conversely.

So, Qt is not the same Qt everywhere.

patlecat commented 4 years ago

@tsujan

Actually, it's also wrong to say, "Qt is Qt everywhere" — my bad. There are many places in Qt doc, where it's explained how Linux, MS Windows and macOS have different behaviors regarding this or that method. Also, there have been so many bugs that appear in Windows but not Linux, and conversely.

Qt isn't perfect in many way, don't get me started LOL. But I did code apps that can be run in both OS before (simple apps!). Although I'm not an expert in Linux enough to do this port myself and I suspect it would need an architectural redesign and modernization. But it would be worth it when you could make millions of additional people happy with it! Isn't it worth risking your sanity for this higher goal? 🌍

So, Qt is not the same Qt everywhere.

I never said that it is. But it can be portable if you designed it to be agnostic of the underlying windowing technology, which I hope you did.

tsujan commented 4 years ago

Qt isn't perfect in many way

Those who use Qt in their codes extensively know that it's far from perfect. Actually, a great amount of my coding time is spent on devising workarounds for nasty Qt bugs and, almost with every new Qt version, new nasty bugs appear. Today, I was struggling with a new text editing bug in Qt 5.14.1 and found a workaround for an app of mine after hours...

However, I'm not saying that there's a better alternative.

if you designed it to be agnostic

I've written several Qt programs and worked on more; none of them could have been "agnostic". Theory is different from practice or, as someone used to say, "The map is not the territory."

patlecat commented 4 years ago

Yeah well it is possible nonetheless to design even the Qt themeing with a wrapper that wouldn't disrupt the lib as a whole. Please consider this for a next verison, would be so awesome.

And yeah sadly Qt is still hunting supposedly cool new features more than fixing old bugs and harmonizing the API. Or making QML more useful.

tsujan commented 4 years ago

Actually, you and I agree on basic things here: "Qt isn't perfect in many way" (I not only agreed with you but also emphasized it above), "agnostic design" and possibility of writing "apps that can be run in both OS" (SMPlayer is a good example).

Years ago, a user told me that he succeeded in porting Kvantum to Windows with "small" changes. I wouldn't believe him if he didn't show me screenshots ;) So, Kvantum's code should have been agnostic enough, although my emphasis is always on Linux.

However, I don't and won't have Windows; forking will always be possible for those who do.

tsujan commented 4 years ago

OK, found it: https://github.com/celibol/kvantum-on-windows-with-QT

That's the correct way of doing it: forking. Some screenshots he'd attached: https://github.com/tsujan/Kvantum/issues/200

And here he said about small changes (maybe because of modesty; I don't know): https://github.com/tsujan/Kvantum/issues/199#issuecomment-382028779

Please note that I'm not responsible for the work.

ensisoft commented 3 years ago

@tsujan Sorry I know this issue is closed but since it's relevant I didn't want to open a new one. First of all thanks for building this style engine I really like it a lot on Linux! :+1:

I'm interested in possibly porting it to Windows. If I do this work are you open to PRs and merging the changes into your trunk?

tsujan commented 3 years ago

@ensisoft

Thanks for your interest in Kvantum!

If you want to add Windows support to Kvantum, you could fork it. I'm afraid I can't help you with it, having had no Windows for 15 years.

I don't add support for non-Linux systems here because (1) I don't and won't have a non-Linux system and (2) even if I had, I wouldn't have time for it. Of course, Unix is an exception.

ensisoft commented 3 years ago

@tsujan thanks for the quick reply.

Ok no worris I understand where you're coming from. I'm just not sure that I myself have time to maintain any possible windows port. Doing a one off port would then soon be incompatible with your upstream and would be left to bit rot and that'd be a shame.

patlecat commented 3 years ago

According to this guy (celibol) it's already running under Windows10, guess it wasn't so damn impossible after all? ;) https://github.com/celibol/kvantum-on-windows-with-QT/issues/1#issuecomment-727860477

ensisoft commented 3 years ago

I've forked @celibol (abandoned?) repo and cleaned it up a little bit.

It's still 3 years behind @tsujan upstream but I plan to merge new upstream to it when I have some time.

My latest updates:

There are still some issues regarding setting the themes, basically there's a hacky way to use the PBSSkin style with themes. Needs to be fixed properly at some point

https://github.com/ensisoft/kvantum-on-windows