Revert "Squashed commit of the theme engine support. [2/4]"

This reverts commit 0ef76318b9b8702f04ab9314cab87ed5026461e0, reversing
changes made to d88998211fdb83e8a397272fb20a8997bda4ddba.