internal byte[] ToByteArray()
        {
            int num = 0;

            byte[] array = new byte[SprmSize];
            num += Word97Writer.AddSprm(array, num, 54810, 0, m_borderColorsTop);
            num += Word97Writer.AddSprm(array, num, 54811, 0, m_borderColorsLeft);
            num += Word97Writer.AddSprm(array, num, 54812, 0, m_borderColorsBottom);
            num += Word97Writer.AddSprm(array, num, 54813, 0, m_borderColorsRight);
            return(array);
        }
예제 #2
0
        internal byte[] ToByteArray()
        {
            byte[] array = new byte[SprmSize];
            int    num   = 0;

            num += Word97Writer.AddSprm(array, num, 54802, 0, m_cellShading);
            if (m_cellShading2 != null)
            {
                num += Word97Writer.AddSprm(array, num, 54806, 0, m_cellShading2);
                if (m_cellShading3 != null)
                {
                    num += Word97Writer.AddSprm(array, num, 54796, 0, m_cellShading3);
                }
            }
            return(array);
        }
예제 #3
0
        internal ListLevelOnFile(int level, RPLFormat.ListStyles listStyle, Word97Writer writer)
        {
            m_style   = listStyle;
            _iStartAt = 1;
            int num = 0;

            _grpprlPapx = new byte[0];
            _dxaSpace   = 360;
            _rgbxchNums = new byte[9];
            _dxaIndent  = 0;
            _ixchFollow = 0;
            string fontName = "Arial";

            switch (listStyle)
            {
            case RPLFormat.ListStyles.Numbered:
                _rgbxchNums[0] = 1;
                _bulletText    = new char[2]
                {
                    (char)level,
                    '.'
                };
                switch (level % 3)
                {
                case 0:
                    setNumberFormatInternal(WordNumberFormat.Arabic);
                    break;

                case 1:
                    setNumberFormatInternal(WordNumberFormat.RomanLower);
                    break;

                case 2:
                    setNumberFormatInternal(WordNumberFormat.Lowercase);
                    break;
                }
                break;

            case RPLFormat.ListStyles.Bulleted:
                setNumberFormatInternal(WordNumberFormat.Bullet);
                switch (level % 3)
                {
                case 0:
                    _bulletText = new char[1]
                    {
                        '·'
                    };
                    fontName = "Symbol";
                    break;

                case 1:
                    _bulletText = new char[1]
                    {
                        'o'
                    };
                    fontName = "Courier New";
                    break;

                case 2:
                    _bulletText = new char[1]
                    {
                        '§'
                    };
                    fontName = "Wingdings";
                    break;
                }
                break;

            default:
                setNumberFormatInternal(WordNumberFormat.Bullet);
                _bulletText = new char[1]
                {
                    ' '
                };
                break;
            }
            _grpprlChpx = new byte[20];
            num         = 0;
            int param = writer.WriteFont(fontName);

            num += Word97Writer.AddSprm(_grpprlChpx, num, 19023, param, null);
            num += Word97Writer.AddSprm(_grpprlChpx, num, 19038, param, null);
            num += Word97Writer.AddSprm(_grpprlChpx, num, 19024, param, null);
            num += Word97Writer.AddSprm(_grpprlChpx, num, 19025, param, null);
            int param2 = 20;

            num += Word97Writer.AddSprm(_grpprlChpx, num, 19011, param2, null);
        }