[Kde-bindings] Adding Perl bindings to Qt 4 to the kdebindings tree
Eric Wilhelm
ewilhelm at scratchcomputing.com
Tue Jan 19 20:55:19 UTC 2010
# from Jonathan Yu
# on Tuesday 19 January 2010 05:32:
>I mention this only because Eric wants to fork the bindings
I don't particularly *want* to fork the binding, but I don't think
emulating a C++ API is they way to design a Perl API. That is, the
design of adding a this() keyword (and fundamental parts of the binding
related to that) and the resultant inheritance/method-call mechanism is
foreign to most Perl developers. You get the resulting bugs for free
though.
I have a branch on github which removes the this()-related stuff,
simplifies inheritance, and implements a standard method-calling form.
I cannot see a way to make the two work in the same codebase or via any
sort of compatibility layer (possibly an XS-based compatibility layer
to implement the necessary C global for this(), but I haven't delved
into that.) It's very difficult to have it both ways.
And there are certainly two camps about the interface.
On the one hand, the old PerlQt API would seem familiar to Qt C++ users,
code would translate more easily, and PerlQt3 code would more easily be
brought up to date. On the other hand, it is unfamiliar and
against-the-grain for Perl users who are looking for a GUI toolkit and
even a C++ programmer is going to have to learn Perlism at some point
when using Perl.
I would love to see a compatibility layer based on a this()-less core,
but that is apparently the opposite of the current project momentum,
which leaves those who want the Perl-ish API responsible for
implementing the C++-ish compatibility layer *and* the extensive
changes (many of which I have done.) But I'm not super motivated to
build the compatibility layer and haven't heard a yes or no about what
I've done thus far (so I'm assuming that's a no.)
--Eric
--
... unsustainable. And that word means something -- it doesn't just
mean "we don't like it".
--Michael Pollan
---------------------------------------------------
http://scratchcomputing.com
---------------------------------------------------
More information about the Kde-bindings
mailing list