moved theme selection out