settings.php 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <?php
  2. // This file is part of The Bootstrap 3 Moodle theme
  3. //
  4. // Moodle is free software: you can redistribute it and/or modify
  5. // it under the terms of the GNU General Public License as published by
  6. // the Free Software Foundation, either version 3 of the License, or
  7. // (at your option) any later version.
  8. //
  9. // Moodle is distributed in the hope that it will be useful,
  10. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. // GNU General Public License for more details.
  13. //
  14. // You should have received a copy of the GNU General Public License
  15. // along with Moodle. If not, see <http://www.gnu.org/licenses/>.
  16. /**
  17. * Theme version info
  18. *
  19. * @package theme_bootstrapbase
  20. * @copyright 2014 Bas Brands, www.basbrands.nl
  21. * @authors Bas Brands, David Scotson
  22. * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
  23. */
  24. defined('MOODLE_INTERNAL') || die;
  25. require_once(__DIR__ . "/lib.php");
  26. require_once(__DIR__ . "/simple_theme_settings.class.php");
  27. if ($ADMIN->fulltree) {
  28. $simplesettings = new simple_theme_settings($settings, 'theme_bootstrap');
  29. $simplesettings->add_checkbox('fluidwidth');
  30. $simplesettings->add_checkbox('fonticons');
  31. $simplesettings->add_checkbox('inversenavbar');
  32. $simplesettings->add_checkbox('deletecss');
  33. $simplesettings->add_text('brandfont');
  34. foreach (range(100, 900, 100) as $weight) {
  35. $fontweights[$weight] = get_string("fontweight$weight", 'theme_bootstrap');
  36. }
  37. $simplesettings->add_select('brandfontweight', 400, $fontweights);
  38. $simplesettings->add_checkbox('brandfontitalic');
  39. $simplesettings->add_textarea('customcss');
  40. }