diff --git a/theme/nonzero/layout/frontpage.php b/theme/nonzero/layout/frontpage.php index a53c48a8183..b0abe41fb62 100644 --- a/theme/nonzero/layout/frontpage.php +++ b/theme/nonzero/layout/frontpage.php @@ -1,4 +1,26 @@ . + +/** + * The frontpage layout. + * + * @package theme_nonzero + * @copyright 2010 Patrick Malley + * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later + */ $hasheading = ($PAGE->heading); $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()); diff --git a/theme/nonzero/layout/general.php b/theme/nonzero/layout/general.php index 097a21fce60..9cda44ca58d 100644 --- a/theme/nonzero/layout/general.php +++ b/theme/nonzero/layout/general.php @@ -1,4 +1,26 @@ . + +/** + * The default layout. + * + * @package theme_nonzero + * @copyright 2010 Patrick Malley + * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later + */ $hasheading = ($PAGE->heading); $hasnavbar = (empty($PAGE->layout_options['nonavbar']) && $PAGE->has_navbar()); diff --git a/theme/nonzero/lib.php b/theme/nonzero/lib.php index e119d76b45d..a97045c8077 100644 --- a/theme/nonzero/lib.php +++ b/theme/nonzero/lib.php @@ -29,8 +29,7 @@ function nonzero_process_css($css, $theme) { - - // Set the region-pre and region-post widths + // Set the region-pre and region-post widths. if (!empty($theme->settings->regionprewidth) && !empty($theme->settings->regionpostwidth)) { $regionprewidth = $theme->settings->regionprewidth; $regionpostwidth = $theme->settings->regionpostwidth; @@ -40,8 +39,7 @@ function nonzero_process_css($css, $theme) { } $css = nonzero_set_regionwidths($css, $regionprewidth, $regionpostwidth); - - // Set the custom CSS + // Set the custom CSS. if (!empty($theme->settings->customcss)) { $customcss = $theme->settings->customcss; } else { @@ -49,7 +47,7 @@ function nonzero_process_css($css, $theme) { } $css = nonzero_set_customcss($css, $customcss); - // Return the CSS + // Return the CSS. return $css; } @@ -57,10 +55,10 @@ function nonzero_process_css($css, $theme) { * Sets the region width variable in CSS * * @param string $css - * @param mixed $regionwidth + * @param string $regionprewidth + * @param string $regionpostwidth * @return string */ - function nonzero_set_regionwidths($css, $regionprewidth, $regionpostwidth) { $tag1 = '[[setting:regionprewidth]]'; $tag2 = '[[setting:regionpostwidth]]'; @@ -74,20 +72,18 @@ function nonzero_set_regionwidths($css, $regionprewidth, $regionpostwidth) { } $css = str_replace($tag1, $replacement1.'px', $css); $css = str_replace($tag2, $replacement2.'px', $css); - $css = str_replace($tag3, ($replacement1+$replacement2).'px', $css); - $css = str_replace($tag4, (2*$replacement1+$replacement2).'px', $css); + $css = str_replace($tag3, ($replacement1 + $replacement2).'px', $css); + $css = str_replace($tag4, (2 * $replacement1 + $replacement2).'px', $css); return $css; } - /** * Sets the custom css variable in CSS * * @param string $css - * @param mixed $customcss + * @param string $customcss * @return string */ - function nonzero_set_customcss($css, $customcss) { $tag = '[[setting:customcss]]'; $replacement = $customcss; diff --git a/theme/nonzero/settings.php b/theme/nonzero/settings.php index 1b38d4fb42b..68e52a07be4 100644 --- a/theme/nonzero/settings.php +++ b/theme/nonzero/settings.php @@ -30,7 +30,7 @@ defined('MOODLE_INTERNAL') || die; if ($ADMIN->fulltree) { - // Block region-pre width + // Block region-pre width. $name = 'theme_nonzero/regionprewidth'; $title = get_string('regionprewidth','theme_nonzero'); $description = get_string('regionprewidthdesc', 'theme_nonzero'); @@ -40,7 +40,7 @@ if ($ADMIN->fulltree) { $setting->set_updatedcallback('theme_reset_all_caches'); $settings->add($setting); - // Block region-post width + // Block region-post width. $name = 'theme_nonzero/regionpostwidth'; $title = get_string('regionpostwidth','theme_nonzero'); $description = get_string('regionpostwidthdesc', 'theme_nonzero'); @@ -50,7 +50,7 @@ if ($ADMIN->fulltree) { $setting->set_updatedcallback('theme_reset_all_caches'); $settings->add($setting); - // Custom CSS file + // Custom CSS file. $name = 'theme_nonzero/customcss'; $title = get_string('customcss','theme_nonzero'); $description = get_string('customcssdesc', 'theme_nonzero');