News for hackers. Stuff that matters.
Re:GTK 3.99 by rjeli on Friday July 31, 2020 @08:28PM (#24016058)
I mostly agree with you, whenever I want to put a simple native linux gui on top of some tool I'm disappointed by the difficulty of the GObject api. However, one advantage is that the C abi hasn't budged as the binary lingua franca. The C++ abi can change, but that only happens every decade or so, so it's not that bad. The worse part is that most FFI libraries always support C perfectly and C++ is always "experimental". So you can quickly throw together a library for a language that wraps GTK without worrying about the ABI. The downside is, obviously you want to smooth over GObject in MyCoolPyGTK, so each library develops its own API which you have to learn over and over, and you end up with 12 tabs open of the shoddy MyCoolPyGTK docs, GTK docs, GObject docs, and reverse engineering how they talk to each other behind the scenes. /rant
Re:GTK 3.99 by thayne on Friday July 31, 2020 @09:55PM (#24016644)
I really wish there was a standard stable ABI for namespaces, vtables, and maybe name mangling operators and overloaded functions. In other words, a standard ABI for OOP APIs. The problem with C++ abi isn't just that it can change, but that it is implementation defined,so different compilers produce different abis.
Re:GTK 3.99 by hedora on Friday July 31, 2020 @09:39PM (#24016533)
> However, one advantage is that the C abi hasn't budged as the binary lingua franca.

That’s nice in theory, but hasn’t gtk stopped providing API compatibility between minor releases?

Re:GTK 3.99 by rjeli on Friday July 31, 2020 @09:59PM (#24016669)
Yeah, but that's a slightly different issue. C abi stability means you can use whatever off-the-shelf ffi your language supports.
Re:GTK 3.99 by thayne on Friday July 31, 2020 @10:00PM (#24016677)
That's not the point. The point is other languages don't have FFI for c++ because it doesn't have a stable/standard abi, so it's much harder to make bindings to qt than to gtk for most languages.
Re:GTK 3.99 by hedora on Friday July 31, 2020 @11:00PM (#24016988)
Version one might take a bit longer, but you don’t have to re-write the qt bindings every three months.

I’m all for ABI stability, but without API stability, it’s meaningless.

Re:GTK 3.99 by thayne on Saturday August 01, 2020 @12:32AM (#24017641)
First of all Gtk doesn't require a rewrite every three months...

Secondly, at least for dynamic languages, you typically don't need to worry about wrapping Gtk's API, you just wrap GObject, and use introspection to dynamically generate classes.

Re:GTK 3.99 by p_l on Saturday August 01, 2020 @02:38AM (#24018225)
Just every major release you have to start from scratch, again, including any tooling you might have had for previous version now requiring rewrite from scratch.
Re:GTK 3.99 by MaxBarraclough on Friday July 31, 2020 @09:05PM (#24016302)
How does it compare against COM?
Re:GTK 3.99 by p_l on Saturday August 01, 2020 @02:39AM (#24018234)
From my understanding, pretty badly. COM having an IDL and being way more explicit about things helps.