Fix apple build.

The apple build was broken because the elseif in the CMakeLists is never triggered.

Some code was not properly adapted for the new qtmacgoodies.

Some paths were not adapted to new split.
Why did you change it back? It contains an additional fix for the bring-to-font issue.