public Style() { // Initialize the object this.id = null; this.parent = null; this.NilAnimation = null; this.UpAnimation = null; this.DownAnimation = null; this.IsAnimated = false; this.IsProtected = DefaultSpreadsheet.IsProtected; this.InteriorBrush = new SolidBrush(DefaultSpreadsheet.BackColor); this.InteriorPen = new Pen(this.InteriorBrush, 1.0f); this.Font = new System.Drawing.Font(DefaultSpreadsheet.FontName, DefaultSpreadsheet.FontSize); this.BottomBorder = null; this.LeftBorder = null; this.RightBorder = null; this.TopBorder = null; this.FontBrush = new SolidBrush(DefaultSpreadsheet.ForeColor); this.StringFormat = new StringFormat(); this.StringFormat.Alignment = DefaultSpreadsheet.Alignment; this.StringFormat.LineAlignment = DefaultSpreadsheet.LineAlignment; this.StringFormat.FormatFlags = DefaultSpreadsheet.FormatFlags; this.NumberFormat = DefaultSpreadsheet.Format; // This is a list of all the children styles of this style. this.childStyles = new List <Style>(); }
/// <summary> /// Create a Spreadsheet Cell. /// </summary> /// <param name="spreadsheetRow">The spreadsheet row associated with this cell.</param> /// <param name="spreadsheetColumn">The spreadsheet column associated with this cell.</param> public SpreadsheetCell(SpreadsheetRow spreadsheetRow, SpreadsheetColumn spreadsheetColumn) { // Initialize the Object. this.spreadsheetRow = spreadsheetRow; this.spreadsheetColumn = spreadsheetColumn; this.style = spreadsheetColumn.Style; this.IsModified = true; }
/// <summary> /// Create a column. /// </summary> /// <param name="columnName">The name of the column.</param> public SpreadsheetColumn(string columnName) : base(columnName, typeof(System.Object)) { // Initialize the object this.style = null; this.image = null; this.rectangle = Rectangle.Empty; this.description = string.Empty; }
/// <summary> /// Create a column. /// </summary> /// <param name="columnName">The name of the column.</param> public SpreadsheetColumn() { // Initialize the object base.DataType = typeof(System.Object); this.ColumnIndex = 0; this.ColumnViewIndex = 0; this.style = null; this.image = null; this.rectangle = Rectangle.Empty; this.description = string.Empty; }