Beispiel #1
0
 public Border GetBorder(Border.BorderSide side)
 {
     foreach (Border b in m_Borders)
     {
         if (side == b.Side)
             return b;
     }
     return null;
 }
Beispiel #2
0
 private void SetCellRangeBorders(Rectangle rcRanges, int iWidth, Color colour, Border.BorderSide side)
 {
     // go through them, setting colour.
     for (int iRow = rcRanges.Top; iRow < rcRanges.Bottom; iRow++)
     {
         for (int iCol = rcRanges.Left; iCol < rcRanges.Right; iCol++)
         {
             Cell c = m_cells[iRow, iCol];
             if (c == null)
             {
                 m_cells[iRow, iCol] = new Cell();
                 c = m_cells[iRow, iCol];
             }
             c.Borders.Add(new Border(iWidth, colour, side));
         }
     }
 }