Exemple #1
0
 /**
  * Function: addStylename
  *
  * Adds the specified stylename to the given style if it does not already
  * contain the stylename.
  */
 static function addStylename($style, $stylename)
 {
     if (mxUtils::indexOfStylename($style, $stylename) < 0) {
         if (!isset($style)) {
             $style = "";
         } else {
             if (strlen($style) > 0 && $style[strlen($style) - 1] != ";") {
                 $style .= ";";
             }
         }
         $style .= $stylename;
     }
     return $style;
 }