Esempio n. 1
0
 public bool Equals(ApplicationSetting other)
 {
     return
         (SkipFirstBlankRows == other.skipFirstBlankRows &&
          SkipFirstBlankColumns == other.SkipFirstBlankColumns &&
          TrimLastBlankRows == other.TrimLastBlankRows &&
          TrimLastBlankColumns == other.TrimLastBlankColumns &&
          ExternalCommands.SequenceEqual(other.ExternalCommands) &&
          FileSettings.SequenceEqual(other.FileSettings) &&
          RecentFileSets.SequenceEqual(other.RecentFileSets) &&
          CellWidth == other.cellWidth &&
          AlternatingColorStrings.SequenceEqual(other.AlternatingColorStrings) &&
          ColumnHeaderColorString.Equals(other.ColumnHeaderColorString) &&
          RowHeaderColorString.Equals(other.RowHeaderColorString) &&
          AddedColorString.Equals(other.AddedColorString) &&
          RemovedColorString.Equals(other.RemovedColorString) &&
          ModifiedColorString.Equals(other.ModifiedColorString) &&
          ModifiedRowColorString.Equals(other.ModifiedRowColorString) &&
          ColorModifiedRow.Equals(other.ColorModifiedRow) &&
          SearchHistory.Equals(other.SearchHistory) &&
          FontName.Equals(other.FontName) &&
          LogFormat.Equals(other.LogFormat) &&
          AddedRowLogFormat.Equals(other.AddedRowLogFormat) &&
          RemovedRowLogFormat.Equals(other.RemovedRowLogFormat));
 }
Esempio n. 2
0
        public ApplicationSetting Clone()
        {
            var clone = new ApplicationSetting();

            clone.SkipFirstBlankRows      = SkipFirstBlankRows;
            clone.SkipFirstBlankColumns   = SkipFirstBlankColumns;
            clone.TrimLastBlankRows       = TrimLastBlankRows;
            clone.TrimLastBlankColumns    = TrimLastBlankColumns;
            clone.ExternalCommands        = ExternalCommands.Select(c => c.Clone()).ToList();
            clone.FileSettings            = FileSettings.Select(f => f.Clone()).ToList();
            clone.RecentFileSets          = RecentFileSets.ToList();
            clone.CellWidth               = CellWidth;
            clone.AlternatingColorStrings = new ObservableCollection <string>(AlternatingColorStrings);
            clone.ColumnHeaderColorString = ColumnHeaderColorString;
            clone.RowHeaderColorString    = RowHeaderColorString;
            clone.AddedColorString        = AddedColorString;
            clone.RemovedColorString      = RemovedColorString;
            clone.modifiedColorString     = ModifiedColorString;
            clone.ModifiedRowColorString  = ModifiedRowColorString;
            clone.ColorModifiedRow        = ColorModifiedRow;
            clone.SearchHistory           = new ObservableCollection <string>(SearchHistory);
            clone.FontName            = FontName;
            clone.LogFormat           = LogFormat;
            clone.AddedRowLogFormat   = AddedRowLogFormat;
            clone.RemovedRowLogFormat = RemovedRowLogFormat;

            return(clone);
        }