[Kde-games-devel] KGameTheme Question
Mauricio Piacentini
piacentini at kde.org
Mon Aug 18 21:49:08 CEST 2008
cc'ing the lists for help:
David Capel wrote:
> Hi, I'm the GSoC student that is recreating Parley's practice (and using
> KGameTheme for its themes), if you don't remember.
>
> As I was finishing up, I decided it would be a good time to test the
> creation and handling of multiple themes. Everything went fine except that I
> can't get KGameThemeSelector to find my .desktop files.
>
> Here is my code for the invocation of it:
>
> void ParleyPracticeMainWindow::slotCreatePreferencesDialog()
> {
> KConfigDialog *dialog = new KConfigDialog(this, "settings",
> Prefs::self());
> dialog->addPage(new KGameThemeSelector(dialog, Prefs::self()),
> i18n("Theme"), "game_theme");
> dialog->show();
> }
>
> You can find the rest of the code in SVN if you need it. Am I doing
> something horribly wrong? My code is almost identical to KBlocks's...
>
> The default for the KConfig setting is the default theme and it has worked
> all along (using KGameTheme), so the problem is not loading the themes once
> they are selected.
>
> When I traced through the code, I was it detecting my .desktop files, but it
> doesn't display them or keep them internally.
Hi, David. I had a look at the code and it looks fine, other than
missing the correct icon for the theme. But I think the problem can be
solved when we do the right thing and make the kdegameslib module for
people that want to use code in libkdegames: I see that now you are
copying some files from libkdegames to parley/kgametheme, and this is
probably not a good strategy. Translators will have to translate the
strings twice, for example, and bugfixes on one version will not make it
into the other.
The first thing I would try is to use the shared version, by modifying
the CMakeLists.txt and see if this fixes the problem. Does it?
Regards,
Mauricio Piacentini
More information about the kde-games-devel
mailing list