Building RKWard on Mac (continued from private discussion)

René J.V. Bertin rjvbertin at gmail.com
Thu Jun 8 13:58:23 UTC 2017


On Thursday June 08 2017 15:01:55 Thomas Friedrichsmeier wrote:

Hi,

> (Oh, or maybe not hooray. I just noted that this will also attach the
> menubar to the main window, and probably other things that look alien
> on Mac).

That's to be expected when you use Qt's built-in KDE theme (which is only available with qt5-kde). It means you're not getting platform integration features, including the menubar.

> I must admit I did not quite understand what this means in terms of a
> "real" solution. Do I install / depend on kf5-osx-integration, set the
> environment variable, or add theme search paths in the code?

The easiest thing to ensure icon support would be to add $prefix/share/icons to the icon theme search path explicitly when you start the UI, at an appropriate and sufficiently early location. I would of course advise to install the osx-integration package, because with that you also get full colour palette and font role support. Esp. the latter should make the application look a bit better because you no longer get the fallback to the standard 13pt Lucida Grande system font.

> I would have expected to get a null QIcon(), i.e.
>   QIcon::fromTheme("nah-thats-wrong").isNull() == true

Isn't that the same as an empty icon, in practice?

> I don't get to see the issue (probably it's a race condition), so

Do you get rbackend showing up as a generic non-GUI application (terminal icon) with a very curious menubar when you activate it?

> could you try: The best place might be rbackend/rkrinterface.cpp lines
> 327-342. The main window widget can be obtained using
> RKWardMainWindow::getMain().

Doing that from the backend wouldn't work on Mac, the only thing that's currently supported is activating the entire application from with the application itself.

Anyway, I just remembered I still had a .Rprofile lying around that did some probably naughty things tailored for R 2.1 or so at the latest. Removing that file solved the issue.

R.


More information about the kde-mac mailing list