Source for file AttachmentSC.class.php

Documentation is available at AttachmentSC.class.php

  1. <?php
  2.  
  3. require_once(HARMONI."GUIManager/StyleComponent.class.php");
  4.  
  5. /**
  6. * The RepeatSC represents CSS "attachment" value. The allowed values are:
  7. * <ul style="font-family: monospace;">
  8. * <li> scroll </li>
  9. * <li> fixed </li>
  10. * </ul>
  11. * <br /><br />
  12. * The <code>StyleComponent</code> (SC) is the most basic of the three building pieces
  13. * of CSS styles. It combines a CSS property value with a ValidatorRule to ensure that
  14. * the value follows a certain format.<br /><br />
  15. *
  16. * @package harmoni.gui.scs
  17. *
  18. * @copyright Copyright &copy; 2005, Middlebury College
  19. * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License (GPL)
  20. *
  21. * @version $Id: AttachmentSC.class.php,v 1.5 2006/08/15 20:44:58 sporktim Exp $
  22. */
  23. class AttachmentSC extends StyleComponent {
  24.  
  25. /**
  26. * The constructor.
  27. * @param string value The value to assign to this SC.
  28. * @access public
  29. ***/
  30. function AttachmentSC($value) {
  31. $options = array("scroll","fixed");
  32.  
  33. $errDescription = "Could not validate the Attachment StyleComponent value \"%s\".
  34. Allowed values are: ".implode(", ", $options).".";
  35. $displayName = "Attachment";
  36. $description = "Specifies the values for CSS property 'attachment'. Allowed values are:
  37. ".implode(", ", $options).".";
  38. $rule = RegexValidatorRule::getRuleByArray($options);
  39. $this->StyleComponent($value, $rule, $options, true, $errDescription, $displayName, $description);
  40. }
  41. }
  42. ?>

Documentation generated on Wed, 19 Sep 2007 10:21:34 -0400 by phpDocumentor 1.3.0RC3