获取css属性组合
@param e {object} 一组css规则{selector: [], property: [], value: [], id: 0}
selector, property, value分别是css规则的选择器、属性和值，id是规则序号
18278
function(e){
    var property = e.property;
    var ruleIds = this.get('ruleIds');
    var imageIndex = property.indexOf('background');

    if (imageIndex == -1) imageIndex = property.indexOf('background-image');

    ruleIds.push(e.id);
    if (imageIndex > -1) {
      this._collectImages(e, imageIndex);
    }
  }
985681
function (rule) {
        var base = this.base;
        var files = [];
        var style = rule.style;
        var that = this;

        var model = new CssParser
        .Model('CSSFontFaceRule')
        .mix({
            id: '',
            family: '',
            files: files,
            selectors: [],
            chars: [],
            options: {}
        });

        
        // 解析 font 相关属性
        Array.prototype.forEach.call(style, function (key) {

            if (key === 'font-family') {

                model.family = utils.unquotation(style['font-family']);

            } else if (key === 'font') {

                model.options = utils.fontValueParse(style.font) || {};
                model.family = model.options['font-family'];

                if (Array.isArray(model.family)) {
                    model.family = model.family[0];
                }

                delete model.options['font-family'];

            } else if (getFontId.keys.indexOf(key) !== -1) {

                model.options[key] = style[key];
            } 
        });



        if (!model.family) {
            return;
        }


        model.id = getFontId(model.family, model.options);

        
        // 解析字体地址
        var src = utils.srcValueParse(style.src);
        var urls = [];
        src.forEach(function (file) {
            file = utils.resolve(base, file);
            file = that._getUrl(file);
            if (file) {
                urls.push(file);
            }
        });

        files.push.apply(files, urls);

        return model;
    }
1287230
public static void setCSSClass(Element e, String cssclass) {
    setAtt(e, SVGConstants.SVG_CLASS_ATTRIBUTE, cssclass);
  }
523447
function(e) {
      var t = this,
          sidebar = $('.nm-sb'),
          newWidth = startWidth = sidebar.width(),
          startX = e.pageX;
      function drag(e) {
        newWidth = startWidth + (e.pageX - startX);
        sidebar.css({width:newWidth});
        t.tour.css({left: newWidth + t.handleWidth});
        UI.pageView.centerPage();
      }
      function drop(e) {
        t.handle.removeClass('drag');
        $(document).unbind("mousemove", drag).unbind("mouseup", drop);
        // Simulate click?
        if (newWidth === startWidth) {
          newWidth = startWidth === 0 ? Sidebar.prototype.defaults.width : 0;
        }
        // Auto-close?
        else if (newWidth < 30) {
          newWidth = 0;
        }
        // Set the width, center the page, and persist
        t.sidebar.set('width', newWidth);
        sidebar.css({width: newWidth});
        t.tour.css({left: newWidth + t.handleWidth});
        UI.pageView.centerPage();
      }
      $(document).bind("mousemove", drag).bind("mouseup", drop);
      t.handle.addClass('drag');
      drag(e);
      e.preventDefault();
    }
1255050
function (module) {
        "use strict";
    
        // find a css value
        var retrieve = function (value) {
    
            var process = value.split('-');
            value = beyond.css.values;
            for (var i in process) {
    
                value = value[process[i]];
                if (typeof value === 'undefined') return;
    
            }
    
            return value;
    
        };
    
        this.process = function (styles) {
    
            var regexp = /value\((.*?)\)/g, styles;
            var value = regexp.exec(styles);
    
            var replace = {};
    
            while (value) {
    
                var retrieved = retrieve(value[1]);
    
                if (typeof retrieved !== 'string') {
    
                    console.warn(
                        'invalid css value "' + value[1] +
                        '" value, it must be an string and it is ' + typeof retrieved)
    
                }
                else replace[value[0]] = retrieved;
    
                value = regexp.exec(styles);
    
            }
    
            // replace all values with their values
            for (var name in replace) {
    
                var value = replace[name];
                while (styles.indexOf(name) !== -1) {
                    styles = styles.replace(name, value);
                }
    
            }
    
            return styles;
    
        };
    
    }
957825
function(e) {
        if (!this._color) {
            return;
        }
        if (e.type === "DOM") {
            e.style.backgroundColor = this._color;
            e.style.lineHeight = 0;
        } else if (e.type === "canvas") {
            e.ctx.fillStyle = this._color;
            e.ctx.fillRect(e.pos._x, e.pos._y, e.pos._w, e.pos._h);
        } else if (e.type === "webgl") {
            e.program.draw(e, this);
        }
    }
1205882
function(el) {
    if (!el) {
      return false;
    }
    var styles = _getComputedStyle(el, null);
    if (!styles) {
      return false;
    }
    var hasCssHeight = _parseFloat(styles.height) > 0;
    var hasCssWidth = _parseFloat(styles.width) > 0;
    var hasCssTop = _parseFloat(styles.top) >= 0;
    var hasCssLeft = _parseFloat(styles.left) >= 0;
    var cssKnows = hasCssHeight && hasCssWidth && hasCssTop && hasCssLeft;
    var rect = cssKnows ? null : _getElementPosition(el);
    var isVisible = styles.display !== "none" && styles.visibility !== "collapse" && (cssKnows || !!rect && (hasCssHeight || rect.height > 0) && (hasCssWidth || rect.width > 0) && (hasCssTop || rect.top >= 0) && (hasCssLeft || rect.left >= 0));
    return isVisible;
  }
819614
function() {
                // 获取现有颜色映射
                //     resource => color_index
                var colorMapping = this._getResourceColorIndexMapping();

                var resource, used, i;

                used = [];

                // 抽取已经使用的值到 used 数组
                for (resource in colorMapping) {
                    if (Object.prototype.hasOwnProperty.call(colorMapping, resource)) {
                        used.push(colorMapping[resource]);
                    }
                }

                // 枚举所有的可用值，如果还没被使用，返回
                for (i = 0; i < RESOURCE_COLOR_SERIES.length; i++) {
                    if (!~used.indexOf(i)) return i;
                }

                // 没有可用的颜色了
                return -1;
            }
665699
function(elem) {
			elem = $(elem);
			if (!elem.hasClass(this._getMarker())) {
				return;
			}
			var inst = this._getInst(elem);
			if (inst.inline) {
				elem.children('.' + this._disableClass).remove().end().
					find('button,select').prop('disabled', false).end().
					find('a').attr('href', 'javascript:void(0)');
			}
			else {
				elem.prop('disabled', false);
				inst.trigger.filter('button.' + this._triggerClass).prop('disabled', false).end().
					filter('img.' + this._triggerClass).css({opacity: '1.0', cursor: ''});
			}
			this._disabled = $.map(this._disabled,
				function(value) { return (value === elem[0] ? null : value); }); // Delete entry
		}
1295
function (ele) {
            var node = this[0];
            //结点类型判断
            if (node.nodeType === 1 || node.nodeType === 11 || node.nodeType === 9) {
                if(ele instanceof vQ){
                    ele.each(function(inx,ele){
                        node.appendChild(ele);
                    });
                } else if(ele.nodeType){
                    node.appendChild(ele);
                }
                // string array
            }
            return this;
        }
584586
function(element, style) {
  Object.keys(style).forEach(function(key) {
    if (key in element.style) {
      element.style[key] = style[key];
    } else if (prefix(key) in element.style) {
      element.style[prefix(key)] = style[key];
    } else {
      util.warn('No such style property: ' + key);
    }
  });
  return element;
}
772336
function(item, node) {
            var items = this.getThemeItems(node);
            var segment, dir, selector, value, matcher;

            if (item in items) return items[item];

            // 尝试匹配 CSS 数组形式的值
            // 比如 item 为 'pading-left'
            // theme 里有 {'padding': [10, 20]} 的定义，则可以返回 20
            segment = item.split('-');
            if (segment.length < 2) return null;

            dir = segment.pop();
            item = segment.join('-');

            if (item in items) {
                value = items[item];
                if (utils.isArray(value) && (matcher = cssLikeValueMatcher[dir])) {
                    return matcher(value);
                }
                if (!isNaN(value)) return value;
            }

            return null;
        }
894931
function(e){
    var images  = this.images;
    var baseDir = path.dirname(this.get('file'));
    var files   = {};
    var equals = {};

    forEach(images, function(file, id){
      var fullPath = path.resolve(baseDir, file);
      if (files[fullPath] !== undefined) {
        equals[id] = files[fullPath];
      } else {
        //去除重复
        files[fullPath] = id;
      }
    });

    this.equals = equals;

    files = Object.keys(files);
    files.forEach(function(file){
      var fs = require('fs');
      var exists    = fs.existsSync;
      if (!exists(file)){
        Log.error('图片' + path.relative(baseDir, file) + '不存在');
      }
    });

    //获取图片大小
    Api.getImagesSize(files, this._setDef, this);
  }
204804
private void fixInlineElement(Element e) {
    if (e.getClientHeight() == 0 && e.getClientWidth() == 0
        && "inline".equals(curCSS(e, "display", true))) {
      setStyleProperty(e, "display", "inline-block");
      setStyleProperty(e, "width", "auto");
      setStyleProperty(e, "height", "auto");
    }
  }
365593
function (v, e) {
            var self = this, parent = self.get('parent');
            self.callSuper(v, e);
            if (!(e && e.byPassSetHighlightedItem)) {
                if (self.get('rendered')) {
                    parent.set('highlightedItem', v ? self : null);
                } else {
                    if (v) {
                        // do not set null on initializer
                        parent.set('highlightedItem', self);
                    }
                }
            }    // 是否要滚动到当前菜单项(横向，纵向)
            // 是否要滚动到当前菜单项(横向，纵向)
            if (v) {
                var el = self.$el,
                    // 找到向上路径上第一个可以滚动的容器，直到父组件节点（包括）
                    // 找不到就放弃，为效率考虑不考虑 parent 的嵌套可滚动 div
                    p = el.parent(function (e) {
                        return $(e).css('overflow') !== 'visible';
                    }, parent.get('el').parent());
                if (!p) {
                    return;
                }
                el.scrollIntoView(p, {
                    alignWithTop: true,
                    allowHorizontalScroll: true,
                    onlyScrollIfNeeded: true
                });
            }
        }
684332
function setStyle(el, strCss) {
        function endsWith(str, suffix) {
            var l = str.length - suffix.length;
            return l >= 0 && str.indexOf(suffix, l) == l;
        }

        var sty = el.style,
            cssText = sty.cssText;
        if (!endsWith(cssText, ';')) {
            cssText += ';';
        }
        sty.cssText = cssText + strCss;
    }
1191059
function (e) {
    var self = this

    if (self._cfg.delay) {
      // iPad打开键盘时旋转比较慢
      clearTimeout(this._changeTimer)
      self._changeTimer = setTimeout(function () {
        self._fireChange(e)
      }, self._cfg.delay)
    } else {
      self._fireChange(e)
    }
  }