Not logged inOpenClonk Forum
Up Topic Development / Developer's Corner / Removing the GTK platform?
- - By Luchs [de] Date 2016-08-01 12:30
With Sven's Qt editor almost ready for merge, it's time to think about the future of the GTK platform. I based the Linux compatibility work on the SDL platform, which did not have an editor before and thus was easier to adjust. The result is that on the qteditor branch, neither GTK with or without the Qt editor currently build. I'd argue that we're better off removing GTK completely than making it work again:

- SDL is already a dependency for the controller support.

- There is no reason the keep the old editor interface as it's clearly inferior to the cross-platform Qt editor (this applies to all platforms).

- The GTK platform is a lot more complex than the SDL platform, with roughly double lines of code in C4App and C4Window (513 SLOC for SDL, 1027 for GTK. As comparison, Win32 has 851 SLOC and I'm not sure about Mac).

- SDL is a lot more common as a game development base than GTK.

- In the future, we may be able to remove more platforms by switching fullscreen to SDL or Qt for all operating systems (probably doesn't matter which as we won't be able to remove either dependency).

There's obviously also option c) keep the broken GTK code until someone bothers to fix it, but I don't think that's a good idea.

In case someone wonders about the stability of the previously-hidden SDL code: I've played exclusively with an SDL-based engine in the last few months. I had to fix a couple of issues, but it works fine now and apparently crashes less than the Windows engine ;)
Parent - - By Newton [de] Date 2016-08-01 14:00 Edited 2016-08-01 14:03
I agree, the less platform dependent code there is in the codebase that has to be maintained the better. Ditching one platform independent framework if another platform independent framework is already used anyway makes sense to me.

In retrospective, I am really happy about that DirectX got removed a few years ago. Or was it ever? Who did that again?
Parent - - By Isilkor Date 2016-08-02 10:36

> In retrospective, I am really happy about that DirectX got removed a few years ago. Or was it ever? Who did that again?


Tim Blume
Reply
Parent - By Sven2 Date 2016-08-02 15:50
I think that's End
Parent - - By Luchs [de] Date 2016-08-02 20:16
This seems more like the "keep the broken code for a while"-option which I'm trying to avoid here.
Parent - By Isilkor Date 2016-08-03 12:20
Yes, I agree that we should just drop GTK. Nobody is going to fix it, unlike the Qt editor it doesn't work on other platforms, and if against all odds we absolutely have to revive it we have source control.
Reply
Parent - By Günther [de] Date 2016-09-01 01:22
I just want to note that I kept the SDL code around despite it not being used, often broken, and clearly inferior to the other options in case it proved useful later. It's not inconceivable that GTK will get better just like SDL got better. Also, I recently fixed the GTK port to run on windows, and I believe the remaining bugs would have been fixable. That said, GTK and Qt are more similar than SDL is to the other options, so having both doesn't have the same value as having SDL had. And removing the platform abstraction entirely would have other benefits.
Reply
Up Topic Development / Developer's Corner / Removing the GTK platform?

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill