123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147 |
- using System;
- using System.Collections.Generic;
- using System.Text;
- using System.Collections;
- namespace Biff8Excel.Excel
- {
-
-
-
-
- public class ExcelCellLinkDictionary : SortedList<ushort,ExcelCell>
- {
-
-
- ushort m_styleIndex;
-
- bool m_hidden;
- Biff8Excel.Records.Row m_row;
- ExcelCellStyle m_cellStyle;
-
- internal bool AdditionalSpaceAbove
- {
- set { m_row.AdditionalSpaceAbove = value; }
- }
- internal bool AdditionalSpaceBelow
- {
- set { m_row.AdditionalSpaceBelow = value; }
- }
- public ExcelCellLinkDictionary(ExcelWorkbook pWorkbook)
- : base()
- {
- m_row = new Biff8Excel.Records.Row();
-
- m_cellStyle = pWorkbook.CreateStyle();
-
-
- m_cellStyle.RowsInit();
- this.StyleIndex = m_cellStyle.GetXFIndex();
- }
- public ushort Height
- {
-
-
- set { m_row.HeightInPoints = value; }
- get { return m_row.HeightInPoints; }
- }
- public bool Hidden
- {
-
-
- set
- {
- m_hidden = value;
- m_row.Hidden = value;
- }
-
-
- get { return m_hidden; }
- }
-
-
-
-
-
- internal ushort rowNumber
- {
-
-
- set
- {
-
- m_row.RowNumber = value;
- }
-
-
-
- }
- ExcelCell oc;
- internal void SetCell(ushort Column, ExcelCell ocell)
- {
- if (this.TryGetValue(Column, out oc))
- oc = ocell;
- else
- this.AddCell(Column, ocell);
- }
- internal void AddCell(ushort Column, ExcelCell ocell)
- {
- this.Add(Column, ocell);
- }
-
-
-
-
-
-
-
-
-
- public ExcelCellStyle Style
- {
-
-
- internal get { return m_cellStyle; }
- set
- {
- m_cellStyle = value;
- this.StyleIndex = value.GetXFIndex();
- }
- }
- internal ushort StyleIndex
- {
-
-
- set
- {
- m_styleIndex = value;
- m_row.ExtendedFormatIndex = value;
- }
-
-
- get { return m_styleIndex; }
- }
- internal byte[] WriteRecord()
- {
- return m_row.GetByte();
- }
- }
- }
|