Пример #1
0
        public int AddNewStyle(float fontSize, Color color, UNOTextAlign align)
        {
            UNOStatStyle style = new UNOStatStyle(fontSize, color, align);

            stylesCollection.Add(style);
            //return stylesCollection.Count - 1;
            return(stylesCollection.IndexOf(style));
        }
Пример #2
0
        public UNOStatParagraph(string text, UNOStatStyle style, int width, Graphics gr)
        {
            Text  = text;
            Style = style;
            SizeF sz = gr.MeasureString(text, style.TextFont, width, style.SFormat);

            AreaRectangle = new Rectangle(0, 0, width, (int)sz.Height);
        }