Exemplo n.º 1
0
        /**
         * set font scheme property
         *
         * @param scheme - FontScheme enum value
         * @see FontScheme
         */
        public void SetScheme(FontScheme scheme)
        {
            Npoi.Core.OpenXmlFormats.Spreadsheet.CT_FontScheme ctFontScheme = _ctFont.sizeOfSchemeArray() == 0 ? _ctFont.AddNewScheme() : _ctFont.GetSchemeArray(0);
            ST_FontScheme val = (ST_FontScheme)scheme.Value;

            ctFontScheme.val = val;
        }
Exemplo n.º 2
0
 /**
  * get the font scheme property.
  * is used only in StylesTable to create the default instance of font
  *
  * @return FontScheme
  * @see Npoi.Core.XSSF.model.StylesTable#CreateDefaultFont()
  */
 public FontScheme GetScheme()
 {
     Npoi.Core.OpenXmlFormats.Spreadsheet.CT_FontScheme scheme = _ctFont.sizeOfSchemeArray() == 0 ? null : _ctFont.GetSchemeArray(0);
     return(scheme == null ? FontScheme.NONE : FontScheme.ValueOf((int)scheme.val));
 }