public XLConditionalFormat(XLRange range, Boolean copyDefaultModify = false)
 {
     Range             = range;
     Style             = new XLStyle(this, range.Worksheet.Style);
     Values            = new XLDictionary <XLFormula>();
     Colors            = new XLDictionary <XLColor>();
     ContentTypes      = new XLDictionary <XLCFContentType>();
     IconSetOperators  = new XLDictionary <XLCFIconSetOperator>();
     CopyDefaultModify = copyDefaultModify;
 }
Beispiel #2
0
 private XLConditionalFormat(XLStyleValue style)
     : base(XLStyle.Default.Value)
 {
     Id               = Guid.NewGuid();
     Ranges           = new XLRanges();
     Values           = new XLDictionary <XLFormula>();
     Colors           = new XLDictionary <XLColor>();
     ContentTypes     = new XLDictionary <XLCFContentType>();
     IconSetOperators = new XLDictionary <XLCFIconSetOperator>();
 }
        public XLConditionalFormat(XLConditionalFormat other)
        {
            Range            = other.Range;
            Style            = new XLStyle(this, other.Style);
            Values           = new XLDictionary <XLFormula>(other.Values);
            Colors           = new XLDictionary <XLColor>(other.Colors);
            ContentTypes     = new XLDictionary <XLCFContentType>(other.ContentTypes);
            IconSetOperators = new XLDictionary <XLCFIconSetOperator>(other.IconSetOperators);


            ConditionalFormatType = other.ConditionalFormatType;
            TimePeriod            = other.TimePeriod;
            IconSetStyle          = other.IconSetStyle;
            Operator         = other.Operator;
            Bottom           = other.Bottom;
            Percent          = other.Percent;
            ReverseIconOrder = other.ReverseIconOrder;
            ShowIconOnly     = other.ShowIconOnly;
            ShowBarOnly      = other.ShowBarOnly;
        }
Beispiel #4
0
        public XLConditionalFormat(XLConditionalFormat conditionalFormat)
        {
            Id               = Guid.NewGuid();
            Range            = conditionalFormat.Range;
            Style            = new XLStyle(this, conditionalFormat.Style);
            Values           = new XLDictionary <XLFormula>(conditionalFormat.Values);
            Colors           = new XLDictionary <XLColor>(conditionalFormat.Colors);
            ContentTypes     = new XLDictionary <XLCFContentType>(conditionalFormat.ContentTypes);
            IconSetOperators = new XLDictionary <XLCFIconSetOperator>(conditionalFormat.IconSetOperators);


            ConditionalFormatType = conditionalFormat.ConditionalFormatType;
            TimePeriod            = conditionalFormat.TimePeriod;
            IconSetStyle          = conditionalFormat.IconSetStyle;
            Operator           = conditionalFormat.Operator;
            Bottom             = conditionalFormat.Bottom;
            Percent            = conditionalFormat.Percent;
            ReverseIconOrder   = conditionalFormat.ReverseIconOrder;
            ShowIconOnly       = conditionalFormat.ShowIconOnly;
            ShowBarOnly        = conditionalFormat.ShowBarOnly;
            StopIfTrueInternal = OpenXmlHelper.GetBooleanValueAsBool(conditionalFormat.StopIfTrueInternal, true);
        }
 private void CopyDictionary <T>(XLDictionary <T> target, XLDictionary <T> source)
 {
     target.Clear();
     source.ForEach(kp => target.Add(kp.Key, kp.Value));
 }
Beispiel #6
0
 public XLDictionary(XLDictionary <T> other)
 {
     other.Values.ForEach(Add);
 }