Code: Select all
#!/bin/sh
PM_PLUGIN_PATH="/usr/lib64/mozilla/plugins-wrapped:/usr/lib64/firefox/plugins-wrapped"
if [ -z "$MOZ_PLUGIN_PATH" ]; then
export MOZ_PLUGIN_PATH="$PM_PLUGIN_PATH"
else
export MOZ_PLUGIN_PATH="$MOZ_PLUGIN_PATH:$PM_PLUGIN_PATH"
fi
PM_GTKRC_KDE="/usr/local/etc/gtkrc-2.0-kde4-pm"
if [ -r "$PM_GTKRC_KDE" ]; then
export GTK2_RC_FILES="$PM_GTKRC_KDE"
fi
exec /opt/palemoon/palemoon "$@"
/usr/lib64/firefox/plugins-wrapped does not exist on my system, but, since Firefox uses it, it is, presumably, a location where plugins might also end up, so it's better to play it safe and include it in the plugin path.
The second part of the script shows how I got around the problem of PM crashing if the oxygen gtk theme is used. Since I didn't want to stop using oxygen on my desktop, I switched temporarily to another theme, copied ~/.gtkrc-2.0-kde4 to another location, and had PM_GTKRC_KDE point to that copy in /usr/bin/palemoon. I then switched back to oxygen and, hey, presto, I get to use oxygen with all programs except Pale Moon, which uses a different theme!
If you choose to do it this way, you probably want to use a version of .gtkrc-2.0-kde4 that was created on your system, as my version is probably Fedora-specific, but here it is, for completeness:
Code: Select all
# This file was written by KDE
# You can edit it in the KDE control center, under "GTK Styles and Fonts"
include "/usr/share/themes/BlueMenta/gtk-2.0/gtkrc"
style "user-font"
{
font_name="Sans Serif"
}
widget_class "*" style "user-font"
gtk-theme-name="BlueMenta"
gtk-font-name="Sans Serif 10"