[Kde-games-devel] KPat Progress and Regressions
Parker Coates
parker.coates at gmail.com
Thu Nov 12 16:12:47 CET 2009
Hello list,
Since the release of KDE4.3, I've been putting a lot of work into an
internal cleanup of KPat. I don't want to imply that KPat was poorly
rewritten, it's just that it's pretty old. [1] If you don't care
about the details, please just skip down to the bottom to learn what I
need from you. ;)
A couple months back, Coolo and I put a significant effort into
getting KPat's licensing and copyright sorted out. [2] KPat was
started as a KDEification of a Qt only patience game that was released
under a custom license. Over the years, lots of people contributed
code, but few to none bothered adding licenses or copyright
statements. Some code was added under the GPL, but some parts were
version 2 only, while others were version 2 or later. Through some
SVN/CVS spelunking and getting in contact with some long gone authors,
I was able to get the entire code base GPLv2+ compatible and all
future changes fall under that license even when making changes to
files originally under the custom license. Coolo even brought in the
big guns, by having one of Suse's lawyers look over the changes to
make sure the made legal sense.
Over the years, as the Qt and KDE technologies have changed, the game
has been ported along, but it has acquired a fair bit of cruft along
the way. I've removed several large chunks of code that presumably
were quite quite important at one point, but now don't get called at
all. There were cases of tight coupling between classes where it
wasn't really needed. Several classes had member variables that are
set all over the place, but never read. Some files, classes and
methods have been renamed to better indicate what they do. Typical
clean up stuff. [3]
I also took the opportunity to port KPat to the new animation
framework available in Qt4.6. This has brought significant
improvements to animation performance, especially for animations
involving multiple cards. The initial conversion was actually pretty
painless, but it quickly pointed out issues in the surrounding code,
which when fixed (of course) pointed out problems in more surrounding
code, and so on.
So in conclusion, I honestly feel that the KPat code base has been
much improved by my efforts, but it's also been much changed. [4] It
is hardly any surprise that there have been some regressions. :) Thus
far Frederik has been doing an amazing job of finding bugs and crashes
and I've almost been able to keep up with his reporting. I also see
that Ian has just reported a bug as well. The problem is that KPat
contains 12 different games and there just isn't time enough to test
all 12 after each commit and a particular breakage often occurs in
only one or two out of the 12. Fortunately, we still have plenty of
time to iron these out before the release.
So I am asking that if you (or a loved one) play KPat even
semi-regularly, please try out the latest trunk. If you could also try
out some of the games you might not normally play, that would be
greatly appreciated as well. I'm especially interested in any problems
in the animations. If you think you've spotted an issue, but it went
by too fast to be sure, slowing done the animations is relatively
easy. [5] I welcome reports in whatever format you prefer: Bugzilla,
this list, private mail or IRC.
Thanks for your time,
Parker
[1] Last month I deleted a file that hadn't been edited in 11.5 years!
http://websvn.kde.org/trunk/KDE/kdegames/kpat/README?view=log&pathrev=1030963
[2] The legality of its previous state was debatable.
[3] A lot of this work was done with the end goal of making these
classes generic enough to move them to a new libkcardgame to make
writing new card games easier. Whether that'll actually happen remains
to be seen.
[4] The current diff since 4.3 is 27006 lines long. http://pastebin.ca/1668236
[5] Open up speeds.h and adjust the SPEED_FACTOR appropriately and recompile.
More information about the kde-games-devel
mailing list