public IFont GetFontOfFormattingRun(int index)
 {
     if (this.st.sizeOfRArray() == 0)
     {
         return((IFont)null);
     }
     for (int index1 = 0; index1 < this.st.sizeOfRArray(); ++index1)
     {
         CT_RElt rarray = this.st.GetRArray(index1);
         if (index1 == index)
         {
             XSSFFont xssfFont = new XSSFFont(XSSFRichTextString.ToCTFont(rarray.rPr));
             xssfFont.SetThemesTable(this.GetThemesTable());
             return((IFont)xssfFont);
         }
     }
     return((IFont)null);
 }
        public short GetFontAtIndex(int index)
        {
            if (this.st.sizeOfRArray() == 0)
            {
                return(-1);
            }
            int num = 0;

            for (int index1 = 0; index1 < this.st.sizeOfRArray(); ++index1)
            {
                CT_RElt rarray = this.st.GetRArray(index1);
                if (index >= num && index < num + rarray.t.Length)
                {
                    XSSFFont xssfFont = new XSSFFont(XSSFRichTextString.ToCTFont(rarray.rPr));
                    xssfFont.SetThemesTable(this.GetThemesTable());
                    return(xssfFont.Index);
                }
                num += rarray.t.Length;
            }
            return(-1);
        }