Add support for themes and main layout.