[KDE/Mac] Thoughts on standard directories in Qt5 - QStandardPaths

Ian Wadham iandw.au at gmail.com
Sun Dec 7 03:16:39 UTC 2014


Hi Marko,

On 07/12/2014, at 4:36 AM, Marko Käning wrote:
> On 06 Dec 2014, at 18:06 , Marko Käning <mk-lists at email.de> wrote:
>> ---
>> configurePlatformArgs=-DCMAKE_INSTALL_BUNDLEDIR="Applications/KF5" -DDATA_INSTALL_DIR="Library/Application Support"
>> ---
> 
> If I remove the DATA_INSTALL_DIR from the configure options “themes” land in /share/bovo/
> ---
> $ XDG_CONFIG_HOME=/opt/kde/install/darwin/mavericks/clang/kf5-qt5/frameworks/kxmlgui/inst/etc/xdg XDG_DATA_HOME=/opt/kde/install/darwin/mavericks/clang/kf5-qt5/kde/kdegames/bovo/inst/share /opt/kde/install/darwin/mavericks/clang/kf5-qt5/kde/kdegames/bovo/inst/Applications/KF5/bovo.app/Contents/MacOS/bovo 
> Could not find drkonqi at /opt/kde/install/darwin/mavericks/clang/kf5-qt5/frameworks/kcrash/inst/lib/libexec/drkonqi
> Couldn't start kglobalaccel from org.kde.kglobalaccel.service: QDBusError("org.freedesktop.DBus.Error.ServiceUnknown", "The name org.kde.kglobalaccel was not provided by any .service files")
> games.ui: KStandardGameAction::create(  1 = game_new , KActionCollection(0x7ff422e35c70, name = "KXMLGUIClient-KActionCollection")  )
> games.ui: KStandardGameAction::create(  11 = game_quit , KActionCollection(0x7ff422e35c70, name = "KXMLGUIClient-KActionCollection")  )
> games.ui: KStandardGameAction::create(  23 = move_hint , KActionCollection(0x7ff422e35c70, name = "KXMLGUIClient-KActionCollection")  )
> Action does not have the correct properties to be current: ""
> games.ui: KStandardGameAction::create(  13 = move_undo , KActionCollection(0x7ff422e35c70, name = "KXMLGUIClient-KActionCollection")  )
> Cannot open file 'theme.svg', because: No such file or directory
> Icon theme "oxygen" not found.
> kf5.kiconthemes: Couldn't find current icon theme, falling back to default.
> Icon theme "oxygen" not found.
> Error: standard icon theme "oxygen" not found!
> Segmentation fault: 11
> ---
> I get further, but bovo STILL cannot find theme.svg. :-(
> 
> Well there are four theme.svg’s in themes:
> 
> └── share
>    ├── bovo
>    │   └── themes
>    │       ├── gomoku
>    │       │   ├── theme.svg
>    │       │   └── themerc
>    │       ├── highcontrast
>    │       │   ├── theme.svg
>    │       │   └── themerc
>    │       ├── scribble
>    │       │   ├── theme.svg
>    │       │   └── themerc
>    │       └── spacy
>    │           ├── theme.svg
>    │           └── themerc
> 
> What more can one do?

Take some KDE Games guy out and shoot him?… :-)

There is a KF5 porting bug in Bovo.  The source file gui/theme.cc contains
an unported reference to KStandardDirs() (KDE 4's way to find paths):
    themePath = KStandardDirs::locate("appdata", themePath);

I don't know for sure why this would have worked in Linux's KF5, but maybe
something to do with the kde4support temporary library.

Oddly enough, the code in Bovo's gui/mainwindow.cc that finds what
graphics themes exist (in directories called "themes") is correct.  But it
only saves the subdir names (gomoku, highcontrast, scribble and spacy),
not the full paths.  So the Theme constructor has to work the paths out again.

Please hold on and leave Bovo for now until I get time to correct gui/theme.cc,
after I have answered other emails.

All the best, Ian W.




More information about the kde-mac mailing list