A different implementation of theme resource overloading for #1240