示例#1
0
        /// <summary>
        /// Set frame border lines
        /// </summary>
        /// <param name="FrameWidth">Frame line width</param>
        /// <param name="FrameColor">Frame line color</param>
        public void SetFrame
        (
            Double FrameWidth,
            Color FrameColor
        )
        {
            // set is not allowed
            if (Parent.Active || TopBorder == null)
            {
                throw new ApplicationException("Set bordes after SetColumnWidth and before table is active.");
            }

            // define default horizontal borders
            TopBorder.Set(FrameWidth, FrameColor);
            BottomBorder.Set(FrameWidth, FrameColor);
            HeaderHorBorder.Set(FrameWidth, FrameColor);
            CellHorBorder.Clear();

            // vertical border lines
            HeaderVertBorder[0].Set(FrameWidth, FrameColor);
            CellVertBorder[0].Set(FrameWidth, FrameColor);
            for (Int32 Index = 1; Index < Columns; Index++)
            {
                HeaderVertBorder[Index].Clear();
                CellVertBorder[Index].Clear();
            }
            HeaderVertBorder[Columns].Set(FrameWidth, FrameColor);
            CellVertBorder[Columns].Set(FrameWidth, FrameColor);
            return;
        }
示例#2
0
 /// <summary>
 ///     Set header horizontal border line
 /// </summary>
 /// <param name="Width">Line width</param>
 public void SetHeaderHorBorder
 (
     double Width
 )
 {
     TestInit();
     HeaderHorBorder.Set(Width, Color.Black);
 }