Mashing up Drupal themes Colourise and Acquia Slate
Today I started mashing up the Acquia Slate theme with the Colourise theme and managed to port the Acquia slate implementation of taxonomy terms into Colourise. In addition I implemented a configurable theme registry rebuild flag and added a configurable taxonomy term separator into the theme:
- The configurable theme registry rebuild flag will bypass the Drupal theme cache when enabled. This will force Drupal to parse all template files upon every single page load. The advantage is that you can easily tweak your template since the changes are visible after each page load. However this feature will significantly slow down your Drupal environment - there's a reason why the theme registry is cached
- The Acquia Slate theme will display taxonomy terms as per vocabulary lists instead of one big tag list. In addition you can choose which vocabularies to display and which to hide, on a global level but also per content type if needed. This way it somehow duplicates the Term display module, but does in principle not require anymore extra theming work.
The trickiest part was playing around with the PHP code for the theme settings form (the file ‘theme-settings.php’ in your theme directory) and how to propagate this correctly into the template (the file ‘template.php’, ‘page.tpl.php’, ‘node.tpl.php’ and other PHP template files in your theme directory).
The code for writing those Drupal template settings forms is very verbose, and rather hard to read if you're not used to, but you must get across it if you're considering writing your own configurable theme.