예제 #1
0
        public void CopyStyles(CSSObject model, bool overrideValues)
        {
            if (model != null)
            {
                if (string.IsNullOrEmpty(color) || overrideValues)
                {
                    color = model.color;
                }

                if (string.IsNullOrEmpty(font) || overrideValues)
                {
                    font = model.font;
                }

                if (string.IsNullOrEmpty(fontWeight) || overrideValues)
                {
                    fontWeight = model.fontWeight;
                }

                if (string.IsNullOrEmpty(fontSize) || overrideValues)
                {
                    fontSize = model.fontSize;
                }

                if (string.IsNullOrEmpty(fontFamily) || overrideValues)
                {
                    fontFamily = model.fontFamily;
                }
            }
        }
예제 #2
0
 public void CopyStyles(CSSObject model)
 {
     CopyStyles(model, false);
 }