示例#1
0
        private ExcelDocument(SpreadsheetDocument doc)
        {
            _doc = doc;
            WorkbookPart wpart = this.GetOSpreadsheet().WorkbookPart;

            _styles        = new DocumentStyles(wpart);
            _sharedStrings = new DocumentSharedStrings(wpart);
            this.Workbook  = new ExcelWorkbook(this);
        }
 public ExcelBorder(IStylable stylable, DocumentStyles styles, uint?borderId)
 {
     _stylable = stylable;
     _styles   = styles;
     _borderId = borderId;
     if (_borderId != null)
     {
         BorderObject = (Border)_styles.GetBorder(_borderId.Value).CloneNode(true);
     }
     else
     {
         BorderObject = new Border();
     }
 }
示例#3
0
 internal ExcelFill(IStylable stylable, DocumentStyles styles, uint?fillId)
 {
     _stylable = stylable;
     _styles   = styles;
     _fillId   = fillId;
     if (_fillId != null)
     {
         FillObject = (Fill)_styles.GetFill(_fillId.Value).CloneNode(true);
     }
     else
     {
         FillObject = new Fill();
     }
 }
示例#4
0
 internal ExcelFont(IStylable stylable, DocumentStyles styles, uint?fontId)
 {
     _stylable = stylable;
     _styles   = styles;
     _fontId   = fontId;
     if (_fontId != null)
     {
         FontObject = (Font)_styles.GetFont(_fontId.Value).CloneNode(true);
     }
     else
     {
         FontObject = new Font();
     }
 }
示例#5
0
 internal ExcelStyle(IStylable stylable, DocumentStyles styles, uint?baseStyleIndex)
 {
     _stylable       = stylable;
     _styles         = styles;
     this.StyleIndex = baseStyleIndex;
 }
示例#6
0
 internal ExcelNumberFormat(IStylable stylable, DocumentStyles styles, uint numFmtId)
 {
     _stylable = stylable;
     _styles   = styles;
     NumFmtId  = numFmtId;
 }